可以作为工具库使用,没有必要重新发明轮子

http://commons.apache.org/configuration/

 

Commons Configuration provides a generic configuration interface which enables a Java application to read configuration data from a variety of sources.