<bean class=“org.springframework.beans.factory.config.PropertyPlaceholderConfigurer“>
       <property name=“locations“>
              <value>classpath:xxx.properties</value>
       </property>
</bean>

或者

<context:Property-Placeholderlocation=”classpath:xxx.properties”/>

接下来就可以在Bean或者XML用{xxx}的方式调用了

相关文章:

  • 2022-01-13
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-02-08
  • 2022-12-23
猜你喜欢
  • 2021-08-06
  • 2022-12-23
  • 2021-06-07
  • 2021-08-04
  • 2022-02-27
  • 2022-03-03
  • 2021-08-25
相关资源
相似解决方案