首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 软件管理 > 软件架构设计 >

将 java.util.Properties 作为参数传到Spring [初级]

2012-11-14 
将 java.util.Properties 作为参数传入Spring [初级]在一个应用中,需要将 java.util.Properties 作为参数

将 java.util.Properties 作为参数传入Spring [初级]

在一个应用中,需要将 java.util.Properties 作为参数传入 一个类中,并读出其中的一个参数

?

?

如果在src的根路径下有文件test.propertie,其内容是:

testString=this is a test string for the test of a property file

?

则运行程序将打印出这句话

?

1 楼 javapub 2011-12-01   Good, very useful. ecpecially the calss "Configuration "

热点排行