`
nannan408
  • 浏览: 1755103 次
  • 性别: Icon_minigender_1
  • 来自: 深圳
社区版块
存档分类
最新评论

架构师之properties--------------------apache的原始类读取属性,最简单

 
阅读更多
1.前言。
  如题。
2.代码

static String mykey;
	static {
		PropertiesConfiguration config = null;
		try {
			config = new PropertiesConfiguration("aa.properties");
		} catch (ConfigurationException e) {
			logger.error(e.getMessage(), e);
		}
		mykey= config.getString("mykey");
	}
0
0
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics