|
Spring Framework example source code file (propertyPlaceholderConfigurer.xml)
The Spring Framework propertyPlaceholderConfigurer.xml source code
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">
<beans>
<bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="properties">
<props>
<prop key="testBean.name">Rob Harrop
<prop key="testBean.age">100
<prop key="scopeName">myScope
</props>
</property>
</bean>
<bean class="org.springframework.beans.factory.config.CustomScopeConfigurer">
<property name="scopes">
<map>
<entry key="${scopeName}">
<bean class="org.springframework.beans.factory.config.SimpleMapScope"/>
</entry>
</map>
</property>
</bean>
<bean class="org.springframework.jmx.export.MBeanExporter">
<property name="beans">
<map>
<entry key="bean:name=proxyTestBean1">
<ref local="testBean"/>
</entry>
</map>
</property>
<property name="server" ref="server"/>
</bean>
<bean id="testBean" class="org.springframework.jmx.JmxTestBean" scope="myScope">
<property name="name">
<value>${testBean.name}
</property>
<property name="age">
<value>${testBean.age}
</property>
<property name="nickName">
<null/>
</property>
</bean>
</beans>
Other Spring Framework examples (source code examples)Here is a short list of links related to this Spring Framework propertyPlaceholderConfigurer.xml source code file: |
| ... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2024 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.