spring配置文件注解方式引入的两种方式
发布时间:2020-12-15 01:11:23 所属栏目:大数据 来源:网络整理
导读:一、#{beanID['propertiesName']}方式 bean id =" propertyConfigurer " class ="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer" property name ="fileEncoding" value ="utf-8" / ="locations" list value classpath:/config/pa
一、#{beanID['propertiesName']}方式 <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> property name="fileEncoding" value="utf-8" /> ="locations"> list> value>classpath:/config/pay-alipay.properties</property> bean> @Value("#{propertyConfigurer['workFlow.url']}") private String flowUrl; 二、${'propertiesName'}方式 @Value("${material.qrCode.target.url}")
private String qrCodeUrl;
? (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |