Delete trailing whitespace in XML files
This commit is contained in:
parent
078d252d1e
commit
6c530b7bfb
|
|
@ -25,14 +25,14 @@
|
|||
<bean id="buffer" class="java.lang.StringBuffer">
|
||||
<constructor-arg ref="int" />
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="thread" class="java.lang.Thread"/>
|
||||
|
||||
|
||||
<bean id="field" class="org.springframework.beans.factory.config.FieldRetrievingFactoryBean">
|
||||
<property name="targetObject" ref="thread"/>
|
||||
<property name="targetField" value="MAX_PRIORITY"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="secondBuffer" class="java.lang.StringBuffer">
|
||||
<constructor-arg ref="field"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -8,6 +8,5 @@
|
|||
<property name="age"><value>25</value></property>
|
||||
</bean>
|
||||
|
||||
</beans>
|
||||
|
||||
|
||||
</beans>
|
||||
|
||||
|
|
|
|||
|
|
@ -12,5 +12,5 @@
|
|||
<property name="name"><value>bean2</value></property>
|
||||
<property name="objRef"><ref bean="beans1.bean2"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,5 +12,5 @@
|
|||
<property name="name"><value>beans2.bean2</value></property>
|
||||
<property name="objRef"><ref bean="beans1.bean1"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,5 +12,5 @@
|
|||
<property name="name"><value>bean2</value></property>
|
||||
<property name="objRef"><ref bean="beans1.bean2"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,5 +12,5 @@
|
|||
<property name="name"><value>beans2.bean2</value></property>
|
||||
<property name="objRef"><ref bean="beans1.bean1"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@
|
|||
<constructor-arg value="#2"/>
|
||||
</bean>
|
||||
|
||||
<bean id="testBean"
|
||||
<bean id="testBean"
|
||||
class="org.springframework.beans.factory.annotation.CustomAutowireConfigurerTests$TestBean"
|
||||
autowire="constructor"/>
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">
|
||||
|
||||
<beans>
|
||||
|
||||
|
||||
<bean id="prototypeTarget" class="java.util.Date" scope="prototype"/>
|
||||
|
||||
<bean id="prototypeFactory" class="org.springframework.beans.factory.config.ObjectFactoryCreatingFactoryBean">
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
</bean>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="otb" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="age"><value>98</value></property>
|
||||
<property name="spouse">
|
||||
|
|
|
|||
|
|
@ -6,35 +6,35 @@
|
|||
default-lazy-init="true">
|
||||
|
||||
<bean name="spring-init" class="org.springframework.beans.factory.support.security.support.InitBean"/>
|
||||
|
||||
|
||||
<bean name="spring-destroy" class="org.springframework.beans.factory.support.security.support.DestroyBean"/>
|
||||
|
||||
|
||||
<bean name="custom-init" class="org.springframework.beans.factory.support.security.support.CustomCallbackBean"
|
||||
init-method="init"/>
|
||||
|
||||
<bean name="custom-destroy" class="org.springframework.beans.factory.support.security.support.CustomCallbackBean"
|
||||
|
||||
<bean name="custom-destroy" class="org.springframework.beans.factory.support.security.support.CustomCallbackBean"
|
||||
destroy-method="destroy"/>
|
||||
|
||||
<bean name="spring-factory" class="org.springframework.beans.factory.support.security.support.CustomFactoryBean"/>
|
||||
|
||||
|
||||
<bean name="custom-static-factory-method" class="org.springframework.beans.factory.support.security.support.FactoryBean" factory-method="makeStaticInstance"/>
|
||||
|
||||
|
||||
<bean name="factory-bean" class="org.springframework.beans.factory.support.security.support.FactoryBean"/>
|
||||
|
||||
|
||||
<bean name="custom-factory-method" factory-bean="factory-bean" factory-method="makeInstance"/>
|
||||
|
||||
|
||||
<bean name="constructor" class="org.springframework.beans.factory.support.security.support.ConstructorBean"/>
|
||||
|
||||
|
||||
<bean name="working-factory-method" class="org.springframework.beans.factory.support.security.support.FactoryBean" factory-method="protectedStaticInstance"/>
|
||||
|
||||
|
||||
<bean name="container-execution" class="org.springframework.beans.factory.support.security.support.ConstructorBean">
|
||||
<constructor-arg ref="working-factory-method"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean name="property-injection" class="org.springframework.beans.factory.support.security.support.PropertyBean">
|
||||
<property name="securityProperty" value="value"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean name="working-property-injection" class="org.springframework.beans.factory.support.security.support.PropertyBean">
|
||||
<property name="property">
|
||||
<array>
|
||||
|
|
@ -44,7 +44,7 @@
|
|||
</bean>
|
||||
|
||||
<bean name="privileged-static-factory-method" class="java.lang.System" factory-method="getProperties"/>
|
||||
|
||||
|
||||
<!-- check trusted beans -->
|
||||
<bean name="trusted-spring-callbacks" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedSpringCallbacksBean">
|
||||
<constructor-arg value="user1"/>
|
||||
|
|
@ -54,27 +54,27 @@
|
|||
init-method="init" destroy-method="destroy">
|
||||
<constructor-arg value="user1"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean name="trusted-spring-factory" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedFactoryBean">
|
||||
<constructor-arg value="user1"/>
|
||||
</bean>
|
||||
|
||||
<bean name="trusted-static-factory-method" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedFactory"
|
||||
|
||||
<bean name="trusted-static-factory-method" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedFactory"
|
||||
factory-method="makeStaticInstance">
|
||||
<constructor-arg value="user1"/>
|
||||
<constructor-arg value="user1"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean name="trusted-factory-bean" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedFactory">
|
||||
<constructor-arg value="user1"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean name="trusted-factory-method" factory-bean="trusted-factory-bean" factory-method="makeInstance"/>
|
||||
|
||||
|
||||
<bean name="trusted-property-injection" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedBean">
|
||||
<constructor-arg value="user1"/>
|
||||
<property name="property" value="value"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean name="trusted-working-property-injection" class="org.springframework.beans.factory.support.security.CallbacksSecurityTests$NonPrivilegedBean">
|
||||
<constructor-arg value="user1"/>
|
||||
<property name="property">
|
||||
|
|
@ -89,5 +89,5 @@
|
|||
</list>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
@ -11,13 +11,13 @@
|
|||
|
||||
<bean id="defaultTestBean" factory-bean="default" factory-method="getTestBean"
|
||||
init-method="haveBirthday" destroy-method="destroy"/>
|
||||
|
||||
|
||||
<bean id="defaultTestBeanWithInvalidDestroyMethod" factory-bean="default" factory-method="getTestBean"
|
||||
init-method="haveBirthday" destroy-method="xxx" lazy-init="true"/>
|
||||
|
||||
<bean id="defaultTestBean.protected" factory-bean="default" factory-method="protectedGetTestBean"
|
||||
init-method="haveBirthday" destroy-method="destroy"/>
|
||||
|
||||
|
||||
<bean id="defaultTestBean.private" factory-bean="default" factory-method="privateGetTestBean"
|
||||
init-method="haveBirthday" destroy-method="destroy"/>
|
||||
|
||||
|
|
@ -40,7 +40,7 @@
|
|||
<constructor-arg index="1"><value>27</value></constructor-arg>
|
||||
<constructor-arg index="2"><value>gotcha</value></constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="fullWithNull" class="org.springframework.beans.factory.xml.FactoryMethods"
|
||||
factory-method="newInstance" lazy-init="true">
|
||||
<constructor-arg index="2" type="java.lang.Integer"><null/></constructor-arg>
|
||||
|
|
@ -95,7 +95,7 @@
|
|||
<constructor-arg><value>gotcha</value></constructor-arg>
|
||||
<constructor-arg><ref local="juergen"/></constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="noMatchPrototype" class="org.springframework.beans.factory.xml.FactoryMethods"
|
||||
factory-method="newInstance" scope="prototype">
|
||||
<constructor-arg index="0"><ref local="juergen"/></constructor-arg>
|
||||
|
|
@ -114,17 +114,17 @@
|
|||
<!--
|
||||
The class is the factory class, not the created class.
|
||||
-->
|
||||
<bean id="externalFactoryMethodWithoutArgs"
|
||||
<bean id="externalFactoryMethodWithoutArgs"
|
||||
class="org.springframework.beans.factory.xml.TestBeanCreator"
|
||||
factory-method="createTestBean">
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="externalFactoryMethodWithArgs" class="org.springframework.beans.factory.xml.TestBeanCreator"
|
||||
factory-method="createTestBean">
|
||||
<constructor-arg index="0"><value>Rod</value></constructor-arg>
|
||||
<constructor-arg><value type="java.lang.Integer">33</value></constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="instanceFactoryMethodWithoutArgs" factory-bean="instanceFactory" factory-method="defaultInstance"/>
|
||||
|
||||
<!-- Unnamed bean with factory-bean declaration -->
|
||||
|
|
|
|||
|
|
@ -4,14 +4,14 @@
|
|||
xmlns:c="http://www.springframework.org/schema/c"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
|
||||
|
||||
<!--
|
||||
<!--
|
||||
<bean id="simple1" class="org.springframework.tests.sample.beans.DummyBean">
|
||||
<constructor-arg value="name"/>
|
||||
</bean>
|
||||
-->
|
||||
-->
|
||||
<bean id="simple" class="org.springframework.tests.sample.beans.DummyBean" c:_="simple"/>
|
||||
|
||||
<!--
|
||||
<!--
|
||||
<bean id="simple1-ref" class="org.springframework.tests.sample.beans.DummyBean">
|
||||
<constructor-arg ref="name"/>
|
||||
</bean>
|
||||
|
|
@ -21,27 +21,27 @@
|
|||
<bean id="name" class="java.lang.String">
|
||||
<constructor-arg type="java.lang.String" value="some-name" index="0"/>
|
||||
</bean>
|
||||
|
||||
<!--
|
||||
|
||||
<!--
|
||||
<bean id="name-value1" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<constructor-arg name="name" value="foo"/>
|
||||
<constructor-arg name="age" value="10"/>
|
||||
</bean>
|
||||
-->
|
||||
-->
|
||||
<bean id="name-value" class="org.springframework.tests.sample.beans.TestBean" c:age="10" c:name="name-value"/>
|
||||
|
||||
<!--
|
||||
<!--
|
||||
<bean id="name-ref1" class="org.springframework.tests.sample.beans.DummyBean">
|
||||
<constructor-arg name="name" ref="name"/>
|
||||
<constructor-arg name="spouse" ref="name-value"/>
|
||||
</bean>
|
||||
-->
|
||||
<bean id="name-ref" class="org.springframework.tests.sample.beans.DummyBean" c:name-ref="name" c:spouse-ref="name-value"/>
|
||||
|
||||
|
||||
<bean id="indexed-value" class="org.springframework.tests.sample.beans.DummyBean" c:_1="austria" c:_0="at" c:_2="10"/>
|
||||
|
||||
|
||||
<bean id="indexed-ref" class="org.springframework.tests.sample.beans.DummyBean" c:_0-ref="name" c:_1-ref="name-value"/>
|
||||
|
||||
|
||||
<bean id="beanWithRefConstructorArg" class="org.springframework.tests.sample.beans.DummyBean" c:nameRef="silly name" c:ageRef="10"/>
|
||||
|
||||
</beans>
|
||||
|
|
@ -174,13 +174,13 @@
|
|||
<prop key="foo2">bar2</prop>
|
||||
</util:properties>
|
||||
|
||||
<util:properties id="defaultLocalOverrideProperties"
|
||||
<util:properties id="defaultLocalOverrideProperties"
|
||||
location="classpath:/org/springframework/beans/factory/xml/util.properties">
|
||||
<prop key="foo">local</prop>
|
||||
<prop key="foo2">local2</prop>
|
||||
</util:properties>
|
||||
|
||||
<util:properties id="trueLocalOverrideProperties"
|
||||
<util:properties id="trueLocalOverrideProperties"
|
||||
location="classpath:/org/springframework/beans/factory/xml/util.properties"
|
||||
local-override="true">
|
||||
<prop key="foo">local</prop>
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@
|
|||
timeToLiveSeconds="120"
|
||||
overflowToDisk="true"
|
||||
/>
|
||||
|
||||
|
||||
<cache name="myCache1"
|
||||
maxElementsInMemory="300"
|
||||
eternal="false"
|
||||
|
|
@ -46,5 +46,5 @@
|
|||
timeToLiveSeconds="500"
|
||||
overflowToDisk="true"
|
||||
/>
|
||||
|
||||
|
||||
</ehcache>
|
||||
|
|
|
|||
|
|
@ -5,12 +5,12 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
|
||||
<aop:config>
|
||||
<aop:aspect id="afterThrowingAdviceBindingTests" ref="testAspect">
|
||||
<aop:after-throwing
|
||||
method="noArgs"
|
||||
pointcut="execution(* exceptional(..))"
|
||||
pointcut="execution(* exceptional(..))"
|
||||
/>
|
||||
<aop:after-throwing
|
||||
method="oneThrowable"
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
method="oneRuntimeException"
|
||||
throwing="ex"
|
||||
pointcut="execution(* exceptional(..))"
|
||||
/>
|
||||
/>
|
||||
<aop:after-throwing
|
||||
method="noArgsOnThrowableMatch"
|
||||
throwing="java.lang.Throwable"
|
||||
|
|
@ -31,12 +31,12 @@
|
|||
method="noArgsOnRuntimeExceptionMatch"
|
||||
throwing="java.lang.RuntimeException"
|
||||
pointcut="execution(* exceptional(..))"
|
||||
/>
|
||||
</aop:aspect>
|
||||
/>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="testAspect" class="org.springframework.aop.aspectj.AfterThrowingAdviceBindingTestAspect"/>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
@ -4,7 +4,7 @@
|
|||
xmlns:aop="http://www.springframework.org/schema/aop"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
<aop:config>
|
||||
|
||||
<aop:advisor id="lowPrecedenceAdvisor"
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
<aop:advisor id="highPrecedenceAdvisor"
|
||||
advice-ref="highPrecedenceSpringAdvice"
|
||||
pointcut="execution(* getAge(..))"
|
||||
order="90"/>
|
||||
order="90"/>
|
||||
|
||||
<aop:aspect ref="lowPrecedenceAspect" order="1000">
|
||||
|
||||
|
|
@ -49,36 +49,36 @@
|
|||
|
||||
<aop:before
|
||||
method="beforeAdviceOne"
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
<aop:before
|
||||
method="beforeAdviceTwo"
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
<aop:around
|
||||
method="aroundAdviceOne"
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
<aop:around
|
||||
method="aroundAdviceTwo"
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
<aop:after-returning
|
||||
method="afterAdviceOne"
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
<aop:after-returning
|
||||
method="afterAdviceTwo"
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
pointcut="execution(* getAge())"/>
|
||||
|
||||
</aop:aspect>
|
||||
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="highPrecedenceSpringAdvice" class="org.springframework.aop.aspectj.SimpleSpringBeforeAdvice"/>
|
||||
|
||||
<bean id="lowPrecedenceSpringAdvice" class="org.springframework.aop.aspectj.SimpleSpringBeforeAdvice"/>
|
||||
|
||||
|
||||
<bean id="highPrecedenceAspect" class="org.springframework.aop.aspectj.PrecedenceTestAspect">
|
||||
<property name="order" value="10"/>
|
||||
</bean>
|
||||
|
|
@ -86,5 +86,5 @@
|
|||
<bean id="lowPrecedenceAspect" class="org.springframework.aop.aspectj.PrecedenceTestAspect"/>
|
||||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -48,15 +48,15 @@
|
|||
</bean>
|
||||
|
||||
<bean id="counterAspect" class="org.springframework.aop.aspectj.Counter"/>
|
||||
|
||||
|
||||
<aop:config>
|
||||
<aop:advisor pointcut="bean(*This) and !bean(dont*)" advice-ref="testInterceptor"/>
|
||||
</aop:config>
|
||||
</aop:config>
|
||||
|
||||
<bean id="interceptThis" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
<bean id="dontInterceptThis" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
<bean id="testInterceptor" class="org.springframework.aop.aspectj.BeanNamePointcutTests$TestInterceptor"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -6,12 +6,12 @@
|
|||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
<bean id="topsyTurvyAspect" class="org.springframework.aop.aspectj.TopsyTurvyAspect"/>
|
||||
|
||||
|
||||
<bean id="topsyTurvyTarget" class="org.springframework.aop.aspectj.TopsyTurvyTargetImpl"/>
|
||||
|
||||
<aop:config>
|
||||
<aop:aspect id="myAspect" ref="topsyTurvyAspect">
|
||||
<aop:before pointcut-ref="pc1"
|
||||
<aop:before pointcut-ref="pc1"
|
||||
method="before"/>
|
||||
<aop:declare-parents
|
||||
types-matching="*..TopsyTurvyTarget+"
|
||||
|
|
@ -25,8 +25,8 @@
|
|||
<aop:declare-parents
|
||||
types-matching="*..TopsyTurvyTarget+"
|
||||
implement-interface="org.springframework.beans.factory.BeanNameAware"
|
||||
default-impl="org.springframework.aop.aspectj.DeclarationOrderIndependenceTests$BeanNameAwareMixin"/>
|
||||
default-impl="org.springframework.aop.aspectj.DeclarationOrderIndependenceTests$BeanNameAwareMixin"/>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,11 +12,11 @@
|
|||
implement-interface="org.springframework.aop.aspectj.ICounter"
|
||||
delegate-ref="counter"
|
||||
/>
|
||||
</aop:aspect>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
<bean id="noMethodsBean" class="org.springframework.aop.aspectj.NoMethodsBeanImpl"/>
|
||||
|
||||
|
||||
<bean id="counter" class="org.springframework.aop.aspectj.Counter"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
<aop:aspectj-autoproxy proxy-target-class="true">
|
||||
<aop:include name="counterAtAspectJAspect"/>
|
||||
</aop:aspectj-autoproxy>
|
||||
|
||||
|
||||
<bean id="counterAtAspectJAspect"
|
||||
class="org.springframework.aop.aspectj.ImplicitJPArgumentMatchingAtAspectJTests$CounterAtAspectJAspect"/>
|
||||
</beans>
|
||||
|
|
@ -7,12 +7,12 @@
|
|||
|
||||
<aop:config proxy-target-class="true">
|
||||
<aop:aspect ref="counterAspect">
|
||||
<aop:pointcut id="anyOperation"
|
||||
<aop:pointcut id="anyOperation"
|
||||
expression="execution(* org.springframework.tests.sample.beans.TestBean.*(..)) and this(bean) and args(argument)"/>
|
||||
<aop:around pointcut-ref="anyOperation" method="increment" arg-names="bean,argument"/>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name" value="aTestBean"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -5,16 +5,16 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
|
||||
<aop:config>
|
||||
<aop:aspect id="ambiguousAdviceTest" ref="testAspect">
|
||||
<aop:pointcut id="setter" expression="execution(* setName(..)) and args(name)"/>
|
||||
<aop:before pointcut-ref="setter" method="myBeforeAdvice"/>
|
||||
</aop:aspect>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="testAspect" class="org.springframework.aop.aspectj.OverloadedAdviceTestAspect"/>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
@ -5,17 +5,17 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
|
||||
<aop:config>
|
||||
<aop:aspect id="overloadedAdviceTest" ref="testAspect">
|
||||
<aop:pointcut id="setter" expression="execution(* setName(..)) and args(name)"/>
|
||||
<aop:before pointcut-ref="setter" method="myBeforeAdvice(java.lang.String)"/>
|
||||
<aop:before pointcut-ref="setter" method="myBeforeAdvice(int)"/>
|
||||
</aop:aspect>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="testAspect" class="org.springframework.aop.aspectj.OverloadedAdviceTestAspect"/>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
@ -5,7 +5,7 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
|
||||
<aop:config>
|
||||
<aop:aspect id="beforeAdviceBindingTests" ref="testAspect">
|
||||
<aop:pointcut id="foo" expression="execution(* foo(..)) and args(x)"/>
|
||||
|
|
@ -13,7 +13,7 @@
|
|||
<aop:before pointcut-ref="foo" method="doBefore(java.lang.String)"/>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="toBeAdvised" class="org.springframework.aop.aspectj.ToBeAdvised"/>
|
||||
|
||||
<bean id="testAspect" class="org.springframework.aop.aspectj.MyAspect"/>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
|
||||
<aop:config>
|
||||
<aop:aspect id="thisMatcher" ref="testAspect">
|
||||
<aop:before pointcut="execution(* *(..)) and this(java.io.Serializable)" method="toString"/>
|
||||
|
|
@ -18,10 +18,10 @@
|
|||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
<!-- should not be proxied -->
|
||||
<!-- should not be proxied -->
|
||||
<bean id="testClassA" class="org.springframework.aop.aspectj.SubtypeMatchingTestClassA"/>
|
||||
|
||||
<!-- should be proxied -->
|
||||
<!-- should be proxied -->
|
||||
<bean id="testClassB" class="org.springframework.aop.aspectj.SubtypeMatchingTestClassB"/>
|
||||
|
||||
<!-- should be proxied -->
|
||||
|
|
|
|||
|
|
@ -12,6 +12,6 @@
|
|||
|
||||
<bean id="testBean" class="org.springframework.aop.aspectj.ThisAndTargetSelectionOnlyPointcutsAtAspectJTests$TestImpl" />
|
||||
<bean id="testAnnotatedClassBean" class="org.springframework.aop.aspectj.ThisAndTargetSelectionOnlyPointcutsAtAspectJTests$AnnotatedClassTestImpl" />
|
||||
<bean id="testAnnotatedMethodBean" class="org.springframework.aop.aspectj.ThisAndTargetSelectionOnlyPointcutsAtAspectJTests$AnnotatedMethodTestImpl" />
|
||||
|
||||
<bean id="testAnnotatedMethodBean" class="org.springframework.aop.aspectj.ThisAndTargetSelectionOnlyPointcutsAtAspectJTests$AnnotatedMethodTestImpl" />
|
||||
|
||||
</beans>
|
||||
|
|
@ -52,5 +52,5 @@
|
|||
<bean id="thisAsInterfaceAndTargetAsInterfaceCounter" class="org.springframework.aop.aspectj.Counter" />
|
||||
<bean id="thisAsInterfaceAndTargetAsClassCounter" class="org.springframework.aop.aspectj.Counter" />
|
||||
<bean id="testBean" class="org.springframework.aop.aspectj.TestImpl" />
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
@ -16,7 +16,7 @@
|
|||
</bean>
|
||||
|
||||
<bean id="testAspect" class="org.springframework.aop.aspectj.autoproxy.AnnotationBindingTestAspect"/>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.aop.aspectj.autoproxy.AnnotatedTestBeanImpl"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
<aop:around pointcut-ref="anyOperation" method="increment"/>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean" />
|
||||
|
||||
<bean id="interfaceExtendingAspect"
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@
|
|||
<!--
|
||||
<bean class="org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator" />
|
||||
-->
|
||||
|
||||
|
||||
<aop:aspectj-autoproxy/>
|
||||
|
||||
|
||||
<bean class="org.springframework.aop.aspectj.autoproxy.MultiplyReturnValue">
|
||||
<property name="multiple" value="2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -5,12 +5,12 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.0.xsd">
|
||||
|
||||
|
||||
|
||||
<!--
|
||||
<bean
|
||||
<bean
|
||||
class="org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator" />
|
||||
-->
|
||||
|
||||
|
||||
<aop:aspectj-autoproxy proxy-target-class="true" expose-proxy="true"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@
|
|||
<!--
|
||||
<bean class="org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator" />
|
||||
-->
|
||||
|
||||
|
||||
<aop:aspectj-autoproxy/>
|
||||
|
||||
|
||||
<bean class="org.springframework.aop.aspectj.autoproxy.MultiplyReturnValue">
|
||||
<property name="multiple" value="2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -9,12 +9,12 @@
|
|||
scope="prototype">
|
||||
<property name="order" value="5"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="adrian" class="org.springframework.tests.sample.beans.TestBean" scope="prototype">
|
||||
<property name="name" value="adrian"/>
|
||||
<property name="age" value="34"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="juergen" class="org.springframework.tests.sample.beans.TestBean" scope="prototype">
|
||||
<property name="name" value="juergen"/>
|
||||
<property name="age" value="30"/>
|
||||
|
|
|
|||
|
|
@ -8,5 +8,5 @@
|
|||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
<bean id="aspect" class="org.springframework.aop.aspectj.autoproxy.ExceptionHandlingAspect"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
@ -5,28 +5,28 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
|
||||
|
||||
|
||||
|
||||
<!--
|
||||
<bean
|
||||
<bean
|
||||
class="org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator" />
|
||||
-->
|
||||
|
||||
|
||||
<aop:aspectj-autoproxy/>
|
||||
|
||||
<bean
|
||||
|
||||
<bean
|
||||
class="org.springframework.aop.aspectj.autoproxy.MultiplyReturnValue" >
|
||||
<property name="multiple" value="2" />
|
||||
</bean>
|
||||
|
||||
<bean
|
||||
|
||||
<bean
|
||||
class="org.springframework.aop.aspectj.autoproxy.benchmark.TraceAspect" >
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="adrian" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name" value="adrian" />
|
||||
<property name="age" value="34" />
|
||||
</bean>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -7,8 +7,8 @@
|
|||
|
||||
<aop:aspectj-autoproxy/>
|
||||
|
||||
<bean id="service" class="org.springframework.aop.aspectj.autoproxy.spr3064.ServiceImpl"/>
|
||||
<bean id="service" class="org.springframework.aop.aspectj.autoproxy.spr3064.ServiceImpl"/>
|
||||
|
||||
<bean id="transactionInterceptor" class="org.springframework.aop.aspectj.autoproxy.spr3064.TransactionInterceptor"/>
|
||||
<bean id="transactionInterceptor" class="org.springframework.aop.aspectj.autoproxy.spr3064.TransactionInterceptor"/>
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:aop="http://www.springframework.org/schema/aop"
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:aop="http://www.springframework.org/schema/aop"
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
<aop:config>
|
||||
<aop:aspect id="countAgeCalls" ref="countingAdvice">
|
||||
<aop:before pointcut="execution(* setAge(..)) and args(age) and this(bean)"
|
||||
<aop:before pointcut="execution(* setAge(..)) and args(age) and this(bean)"
|
||||
method="mySetAgeAdvice" arg-names="age,bean"/>
|
||||
</aop:aspect>
|
||||
</aop:config>
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
<bean id="serviceInterceptor" class="org.springframework.aop.interceptor.DebugInterceptor"/>
|
||||
|
||||
<aop:config proxy-target-class="false">
|
||||
<aop:config proxy-target-class="false">
|
||||
<aop:pointcut id="servicePointcut" expression="target(org.springframework.tests.sample.beans.ITestBean)"/>
|
||||
<aop:advisor advice-ref="serviceInterceptor" pointcut-ref="servicePointcut"/>
|
||||
</aop:config>
|
||||
|
|
|
|||
|
|
@ -4,10 +4,10 @@
|
|||
<!--
|
||||
Tests for misconfiguring the proxy factory bean using a target source in the
|
||||
interceptor list as well as set by the targetSource property
|
||||
-->
|
||||
-->
|
||||
|
||||
<beans>
|
||||
|
||||
|
||||
<bean id="eveTargetSource" class="org.springframework.aop.target.SingletonTargetSource">
|
||||
<constructor-arg>
|
||||
<bean class="org.springframework.tests.sample.beans.TestBean">
|
||||
|
|
@ -15,40 +15,40 @@
|
|||
</bean>
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="adam" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Adam</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="adamTargetSource" class="org.springframework.aop.target.SingletonTargetSource">
|
||||
<constructor-arg>
|
||||
<ref local="adam"/>
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="countingBeforeAdvice"
|
||||
class="org.springframework.tests.aop.advice.CountingBeforeAdvice"
|
||||
/>
|
||||
|
||||
|
||||
<bean id="doubleTarget"
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="proxyInterfaces"><value>org.springframework.tests.sample.beans.ITestBean</value></property>
|
||||
<!-- this is the one used and NOT the one set by targetSource -->
|
||||
<property name="interceptorNames"><value>countingBeforeAdvice,adamTargetSource</value></property>
|
||||
|
||||
|
||||
<property name="targetSource"><ref bean="eveTargetSource"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!-- but this is also possible -->
|
||||
<bean id="arbitraryTarget"
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="proxyInterfaces"><value>org.springframework.tests.sample.beans.ITestBean</value></property>
|
||||
<!-- this is the one used and NOT the one set by targetSource -->
|
||||
<property name="interceptorNames"><value>adam</value></property>
|
||||
<property name="targetSource"><ref local="eveTargetSource"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
||||
|
||||
</beans>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -4,31 +4,31 @@
|
|||
<!--
|
||||
Tests for misconfiguring the proxy factory bean using a target source in the
|
||||
interceptor list as well as set by the targetSource property
|
||||
-->
|
||||
-->
|
||||
|
||||
<beans>
|
||||
|
||||
|
||||
|
||||
|
||||
<bean id="adam" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Adam</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="countingBeforeAdvice"
|
||||
class="org.springframework.tests.aop.advice.CountingBeforeAdvice"
|
||||
/>
|
||||
|
||||
|
||||
<!--
|
||||
An error, as the target source or non-advice object
|
||||
must be last
|
||||
-->
|
||||
<bean id="targetSourceNotLast"
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
-->
|
||||
<bean id="targetSourceNotLast"
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="proxyInterfaces"><value>org.springframework.tests.sample.beans.ITestBean</value></property>
|
||||
<!-- this is the one used and NOT the one set by targetSource -->
|
||||
<property name="interceptorNames"><value>adam,countingBeforeAdvice</value></property>
|
||||
|
||||
|
||||
</bean>
|
||||
|
||||
</beans>
|
||||
|
||||
|
||||
</beans>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
<bean id="test" class="org.springframework.tests.sample.beans.SideEffectBean">
|
||||
<property name="count"><value>10</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="prototypeTarget" class="org.springframework.tests.sample.beans.SideEffectBean" scope="prototype">
|
||||
<property name="count"><value>10</value></property>
|
||||
</bean>
|
||||
|
|
@ -25,7 +25,7 @@
|
|||
<property name="interceptorNames"><value>debugInterceptor,prototypeTarget</value></property>
|
||||
<property name="singleton"><value>false</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="cglibPrototype"
|
||||
class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="interceptorNames"><value>debugInterceptor,prototypeTarget</value></property>
|
||||
|
|
|
|||
|
|
@ -4,20 +4,20 @@
|
|||
<beans>
|
||||
|
||||
<bean id="testBeanTarget" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
<bean id="simpleBeforeAdvice" class="org.springframework.aop.framework.adapter.SimpleBeforeAdviceImpl"/>
|
||||
|
||||
|
||||
<bean id="simpleBeforeAdviceAdvisor" class="org.springframework.aop.support.DefaultPointcutAdvisor">
|
||||
<constructor-arg><ref local="simpleBeforeAdvice"/></constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="proxyInterfaces"><value>org.springframework.tests.sample.beans.ITestBean</value></property>
|
||||
<property name="interceptorNames"><value>simpleBeforeAdviceAdvisor,testBeanTarget</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="testAdvisorAdapter" class="org.springframework.aop.framework.adapter.SimpleBeforeAdviceAdapter"/>
|
||||
|
||||
|
||||
<bean id="adapterRegistrationManager" class="org.springframework.aop.framework.adapter.AdvisorAdapterRegistrationManager"/>
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -2,20 +2,20 @@
|
|||
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">
|
||||
|
||||
<beans>
|
||||
|
||||
|
||||
<bean id="testBeanTarget" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
<bean id="simpleBeforeAdvice" class="org.springframework.aop.framework.adapter.SimpleBeforeAdviceImpl"/>
|
||||
|
||||
|
||||
<bean id="simpleBeforeAdviceAdvisor" class="org.springframework.aop.support.DefaultPointcutAdvisor">
|
||||
<constructor-arg><ref local="simpleBeforeAdvice"/></constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="testBean" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="proxyInterfaces"><value>org.springframework.tests.sample.beans.ITestBean</value></property>
|
||||
<property name="interceptorNames"><value>simpleBeforeAdviceAdvisor,testBeanTarget</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="testAdvisorAdapter" class="org.springframework.aop.framework.adapter.SimpleBeforeAdviceAdapter"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
<bean id="aapc"
|
||||
class="org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator">
|
||||
|
||||
|
||||
<!-- This common interceptor will be applied always,
|
||||
before custom lockable advisor -->
|
||||
<property name="interceptorNames">
|
||||
|
|
@ -30,18 +30,17 @@
|
|||
class="test.mixin.LockMixinAdvisor"
|
||||
scope="prototype"
|
||||
/>
|
||||
|
||||
|
||||
<bean id="test1"
|
||||
class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="age"><value>4</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="test2"
|
||||
class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="age"><value>4</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
||||
|
||||
|
||||
</beans>
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
</list>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="aapc.quickTargetSourceCreator"
|
||||
class="org.springframework.aop.framework.autoproxy.target.QuickTargetSourceCreator"/>
|
||||
|
||||
|
|
@ -18,27 +18,27 @@
|
|||
<property name="name"><value>Rod</value></property>
|
||||
<property name="spouse"><ref local="wife"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="wife" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Kerry</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!-- Prefix means it will be pooled -->
|
||||
<bean id=":test" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Rod</value></property>
|
||||
<property name="spouse"><ref local="wife"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!-- Prefix means it will be thread local -->
|
||||
<bean name="%test" scope="prototype" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Rod</value></property>
|
||||
<property name="spouse"><ref local="wife"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!-- Prefix means it will be a prototype target source -->
|
||||
<bean name="!test" scope="prototype" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Rod</value></property>
|
||||
<property name="spouse"><ref local="wife"/></property>
|
||||
</bean>
|
||||
|
||||
</beans>
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -26,4 +26,4 @@
|
|||
|
||||
<bean id="bean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
</beans>
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
<bean id="testBean" class="org.springframework.tests.sample.beans.TestBean" scope="request">
|
||||
<aop:scoped-proxy proxy-target-class="false"/>
|
||||
<property name="age" value="99"/>
|
||||
<property name="age" value="99"/>
|
||||
</bean>
|
||||
|
||||
<bean class="org.springframework.beans.factory.config.PropertyOverrideConfigurer">
|
||||
|
|
|
|||
|
|
@ -2,21 +2,21 @@
|
|||
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">
|
||||
|
||||
<beans>
|
||||
|
||||
|
||||
<bean id="prototypeTest" class="org.springframework.tests.sample.beans.SideEffectBean" scope="prototype">
|
||||
<property name="count"><value>10</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="poolTargetSource" class="org.springframework.aop.target.CommonsPool2TargetSource">
|
||||
<property name="targetBeanName"><value>prototypeTest</value></property>
|
||||
<property name="maxSize"><value>25</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="poolConfigAdvisor" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
||||
<property name="targetObject"><ref local="poolTargetSource" /></property>
|
||||
<property name="targetMethod"><value>getPoolingConfigMixin</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="nop" class="org.springframework.tests.aop.interceptor.NopInterceptor"/>
|
||||
|
||||
<!--
|
||||
|
|
@ -26,11 +26,11 @@
|
|||
<property name="targetSource"><ref local="poolTargetSource"/></property>
|
||||
<property name="interceptorNames"><value>nop</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="pooledNoInterceptors" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="targetSource"><ref local="poolTargetSource"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="pooledWithMixin" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="targetSource"><ref local="poolTargetSource"/></property>
|
||||
<property name="interceptorNames"><value>poolConfigAdvisor</value></property>
|
||||
|
|
@ -41,18 +41,18 @@
|
|||
|
||||
<!-- Serialization tests using serializable target and advice -->
|
||||
<bean id="serializableNop" class="org.springframework.tests.aop.interceptor.SerializableNopInterceptor" />
|
||||
|
||||
|
||||
<bean id="prototypePerson" class="org.springframework.tests.sample.beans.SerializablePerson" scope="prototype"/>
|
||||
|
||||
<bean id="personPoolTargetSource" class="org.springframework.aop.target.CommonsPool2TargetSource">
|
||||
<property name="targetBeanName"><value>prototypePerson</value></property>
|
||||
<property name="maxSize"><value>10</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="pooledPerson" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="targetSource"><ref local="personPoolTargetSource"/></property>
|
||||
<property name="interceptorNames"><value>serializableNop</value></property>
|
||||
|
||||
|
||||
</bean>
|
||||
|
||||
<bean id="maxSizePooledPerson" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
|
|
@ -66,4 +66,4 @@
|
|||
<property name="interceptorNames"><value>serializableNop</value></property>
|
||||
</bean>
|
||||
|
||||
</beans>
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -2,38 +2,38 @@
|
|||
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">
|
||||
|
||||
<beans>
|
||||
|
||||
<!--
|
||||
|
||||
<!--
|
||||
Not yet in use: illustration of possible approach.
|
||||
-->
|
||||
<bean id="autoProxiedOverload" lazy-init="true"
|
||||
class="org.springframework.beans.factory.xml.OverloadLookup">
|
||||
<lookup-method name="newTestBean" bean="jenny"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="regularlyProxiedOverloadTarget" scope="prototype"
|
||||
class="org.springframework.beans.factory.xml.OverloadLookup">
|
||||
<lookup-method name="newTestBean" bean="jenny"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="regularlyProxiedOverload" lazy-init="true" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="target"><ref local="regularlyProxiedOverloadTarget"/></property>
|
||||
<property name="proxyTargetClass"><value>true</value></property>
|
||||
<property name="interceptorNames"><value>interceptor</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="jenny" class="org.springframework.tests.sample.beans.TestBean" scope="prototype">
|
||||
<property name="name"><value>Jenny</value></property>
|
||||
<property name="age"><value>30</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!-- Add autoproxy -->
|
||||
<bean class="org.springframework.aop.framework.autoproxy.BeanNameAutoProxyCreator">
|
||||
<property name="beanNames"><value>autoProxiedOverload</value></property>
|
||||
<property name="proxyTargetClass"><value>true</value></property>
|
||||
<property name="interceptorNames"><value>interceptor</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="interceptor" class="org.springframework.aop.interceptor.DebugInterceptor"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -58,5 +58,5 @@
|
|||
<bean id="thetaFactory" class="org.springframework.beans.factory.xml.QualifierAnnotationTests$QualifiedFactoryBean"/>
|
||||
|
||||
<bean id="thetaImpl" class="org.springframework.beans.factory.xml.QualifierAnnotationTests$ThetaImpl"/>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
<property name="name"><value>override</value></property>
|
||||
<!-- age should inherit value of 1 from parent -->
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="inheritsWithDifferentClass" class="org.springframework.tests.sample.beans.DerivedTestBean"
|
||||
parent="inheritedTestBean" init-method="initialize">
|
||||
<property name="name"><value>override</value></property>
|
||||
|
|
@ -24,17 +24,17 @@
|
|||
<property name="name"><value>prototypeOverridesInheritedSingleton</value></property>
|
||||
<!-- age should inherit value of 1 from parent -->
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="prototypeInheritsFromParentFactoryPrototype" parent="inheritedTestBeanPrototype" scope="prototype">
|
||||
<property name="name"><value>prototype-override</value></property>
|
||||
<!-- age should inherit value of 2 from parent -->
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="singletonInheritsFromParentFactoryPrototype" parent="inheritedTestBeanPrototype" scope="singleton">
|
||||
<property name="name"><value>prototype-override</value></property>
|
||||
<!-- age should inherit value of 2 from parent -->
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="inheritedTestBean" parent="inheritedTestBean">
|
||||
<property name="name"><value>overrideParentBean</value></property>
|
||||
<!-- age should inherit value of 1 from parent -->
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
<property name="proxyInterfaces" value="org.springframework.tests.sample.beans.ITestBean"/>
|
||||
<property name="targetName" value="target2"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="target2" class="org.springframework.tests.sample.beans.DependenciesBean">
|
||||
<property name="spouse">
|
||||
<bean class="org.springframework.tests.sample.beans.TestBean">
|
||||
|
|
|
|||
|
|
@ -3,28 +3,28 @@
|
|||
|
||||
<beans>
|
||||
|
||||
<bean id="constructorOverrides"
|
||||
<bean id="constructorOverrides"
|
||||
class="org.springframework.beans.factory.xml.ConstructorInjectedOverrides"
|
||||
autowire="autodetect">
|
||||
|
||||
|
||||
<!--
|
||||
We combine a setter method with constructor
|
||||
autowiring
|
||||
-->
|
||||
<property name="setterString"><value>from property element</value></property>
|
||||
|
||||
<lookup-method name="createFactoryMethods" bean="factoryMethods" />
|
||||
|
||||
|
||||
<lookup-method name="createFactoryMethods" bean="factoryMethods" />
|
||||
|
||||
</bean>
|
||||
|
||||
|
||||
|
||||
|
||||
<bean id="jenny" class="org.springframework.tests.sample.beans.TestBean"
|
||||
scope="singleton">
|
||||
<property name="name"><value>Jenny</value></property>
|
||||
<property name="age"><value>30</value></property>
|
||||
</bean>
|
||||
|
||||
<bean id="factoryMethods"
|
||||
|
||||
<bean id="factoryMethods"
|
||||
class="org.springframework.beans.factory.xml.FactoryMethods"
|
||||
factory-method="newInstance"
|
||||
scope="prototype">
|
||||
|
|
|
|||
|
|
@ -5,17 +5,17 @@
|
|||
|
||||
<bean id="constructorOverrides" class="org.springframework.beans.factory.xml.ConstructorInjectedOverrides"
|
||||
autowire="autodetect">
|
||||
|
||||
|
||||
<!-- No such lookup method -->
|
||||
<lookup-method name="bogusMethod" bean="dummyBo" />
|
||||
|
||||
|
||||
</bean>
|
||||
|
||||
<bean id="jenny" class="org.springframework.tests.sample.beans.TestBean" scope="singleton">
|
||||
<property name="name"><value>Jenny</value></property>
|
||||
<property name="age"><value>30</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="factoryMethods" class="org.springframework.beans.factory.xml.FactoryMethods"
|
||||
factory-method="newInstance" scope="prototype">
|
||||
<constructor-arg index="0"><ref local="jenny"/></constructor-arg>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd">
|
||||
|
||||
<!-- just ensures that one can use <ref local=""/> to refer to the various <util:collections/> types -->
|
||||
|
||||
|
||||
<util:map id="map"/>
|
||||
<util:list id="list"/>
|
||||
<util:set id="set"/>
|
||||
|
|
|
|||
|
|
@ -3,15 +3,15 @@
|
|||
|
||||
<beans>
|
||||
|
||||
|
||||
|
||||
<bean id="default" class="org.springframework.beans.factory.xml.FactoryMethods"
|
||||
factory-method="defaultInstance">
|
||||
<!-- No constructor-arg elements -->
|
||||
<property name="stringValue"><value>setterString</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="defaultTestBean" factory-bean="default" factory-method="xgetTestBean"
|
||||
init-method="haveBirthday" destroy-method="destroy"/>
|
||||
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
<lookup-method name="getPrototypeDependency" bean="jenny"/>
|
||||
<lookup-method name="protectedOverrideSingleton" bean="david"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<!--
|
||||
Test that overrides work on an inherited method
|
||||
-->
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
<lookup-method name="getPrototypeDependency" bean="jenny"/>
|
||||
<lookup-method name="protectedOverrideSingleton" bean="david"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<!--
|
||||
We can use this to test the construction cost of beans with method overrides
|
||||
-->
|
||||
|
|
@ -33,8 +33,8 @@
|
|||
<lookup-method name="getPrototypeDependency" bean="david"/>
|
||||
<lookup-method name="protectedOverrideSingleton" bean="jenny"/>
|
||||
</bean>
|
||||
|
||||
|
||||
|
||||
|
||||
<bean id="jenny" class="org.springframework.tests.sample.beans.TestBean" scope="prototype">
|
||||
<property name="name"><value>Jenny</value></property>
|
||||
<property name="age"><value>30</value></property>
|
||||
|
|
@ -45,7 +45,7 @@
|
|||
<bean class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="jennyParent" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name"><value>Jenny</value></property>
|
||||
<property name="age"><value>30</value></property>
|
||||
|
|
@ -70,12 +70,12 @@
|
|||
</property>
|
||||
<property name="age"><value>27</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="magicDavid" class="org.springframework.tests.sample.beans.TestBean" autowire="byName"/>
|
||||
|
||||
|
||||
<!-- this should be autowired as well! -->
|
||||
<bean id="magicDavidDerived" parent="magicDavid" />
|
||||
|
||||
|
||||
<bean id="spouse" class="org.springframework.tests.sample.beans.TestBean">
|
||||
<property name="name" value="Linda"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -3,6 +3,6 @@
|
|||
|
||||
<beans>
|
||||
|
||||
<import resource="XmlBeanFactoryTests-recursiveImport.xml"/>
|
||||
<import resource="XmlBeanFactoryTests-recursiveImport.xml"/>
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
<beans>
|
||||
|
||||
<import resource="XmlBeanFactoryTests-resourceImport.xml"/>
|
||||
<import resource="XmlBeanFactoryTests-resourceImport.xml"/>
|
||||
|
||||
<bean id="resource2" class="org.springframework.tests.sample.beans.ResourceTestBean">
|
||||
<constructor-arg index="0" value="classpath:org/springframework/beans/factory/xml/test.properties"/>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<property name="age"><value>33</value></property>
|
||||
<property name="name"><value>Rod</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="kerry" class="org.springframework.tests.sample.beans.TestBean"
|
||||
dependency-check="none">
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
<bean id="a" class="org.springframework.tests.sample.beans.DependenciesBean" dependency-check="objects">
|
||||
<property name="spouse"><ref local="kerry"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="kerry" class="org.springframework.tests.sample.beans.TestBean" dependency-check="none">
|
||||
</bean>
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
<property name="age"><value>33</value></property>
|
||||
<property name="name"><value>Rod</value></property>
|
||||
</bean>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
<property name ="name"><value>tony</value></property>
|
||||
<property name="spouse"><ref local="kerry"></property> -->
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="kerry" class="org.springframework.tests.sample.beans.TestBean"
|
||||
dependency-check="none">
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -6,9 +6,9 @@
|
|||
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
|
||||
|
||||
<bean id="proxiedXmlBean" class="org.springframework.tests.sample.beans.TestBean"/>
|
||||
|
||||
|
||||
<bean id="anAspect" class="org.springframework.context.annotation.configuration.ImportResourceTests$AnAspect"/>
|
||||
|
||||
|
||||
<aop:aspectj-autoproxy>
|
||||
<aop:include name="anAspect"/>
|
||||
</aop:aspectj-autoproxy>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -19,7 +19,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
<context:component-scan base-package="org.springframework.context.annotation"
|
||||
use-default-filters="false"
|
||||
annotation-config="false">
|
||||
<context:include-filter type="assignable"
|
||||
<context:include-filter type="assignable"
|
||||
expression="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$DefaultsTestBean"/>
|
||||
</context:component-scan>
|
||||
|
||||
|
|
@ -20,7 +20,7 @@
|
|||
<constructor-arg value="pd1"/>
|
||||
</bean>
|
||||
|
||||
<bean id="propertyDependency2"
|
||||
<bean id="propertyDependency2"
|
||||
class="org.springframework.context.annotation.ComponentScanParserBeanDefinitionDefaultsTests$PropertyDependencyTestBean">
|
||||
<constructor-arg value="pd2"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -53,5 +53,5 @@
|
|||
</bean>
|
||||
|
||||
<context:annotation-config />
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
|
||||
|
||||
<import resource="ClassPathXmlApplicationContextTests-resourceIm*.xml"/>
|
||||
<import resource="ClassPathXmlApplicationContextTests-resourceIm*.xml"/>
|
||||
|
||||
<bean id="resource2" class="org.springframework.tests.sample.beans.ResourceTestBean">
|
||||
<constructor-arg name="inputStream">
|
||||
|
|
|
|||
|
|
@ -12,5 +12,5 @@
|
|||
<bean class="org.springframework.context.support.Spr7283Tests$A"/>
|
||||
<bean class="org.springframework.context.support.Spr7283Tests$B"/>
|
||||
</util:list>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -15,5 +15,5 @@
|
|||
</map>
|
||||
</constructor-arg>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
<!--<property name="assembler"><ref bean="assemblerOne"/></property>-->
|
||||
<property name="assembler"><ref bean="myTarget"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
<alias name="${targetName}" alias="myTarget"/>
|
||||
|
||||
<alias name="${realLogicName}" alias="${logicName}"/>
|
||||
|
|
|
|||
|
|
@ -7,5 +7,5 @@
|
|||
<!--<property name="assembler"><ref bean="assemblerTwo"/></property>-->
|
||||
<property name="assembler"><ref bean="wrappedAssemblerTwo"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -13,5 +13,5 @@
|
|||
<!--<property name="assembler"><ref bean="assemblerOne"/></property>-->
|
||||
<property name="assembler"><ref bean="${targetName}"/></property>
|
||||
</bean>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@
|
|||
cache-session-bean="true">
|
||||
<jee:environment>foo=bar</jee:environment>
|
||||
</jee:remote-slsb>
|
||||
|
||||
|
||||
<!-- Lazy beans Tests-->
|
||||
<jee:jndi-lookup id="lazyDataSource" jndi-name="jdbc/MyDataSource" lazy-init="true" />
|
||||
<jee:local-slsb id="lazyLocalBean" jndi-name="ejb/MyLocalBean"
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@
|
|||
<lang:inline-script><![CDATA[
|
||||
int count;
|
||||
void onApplicationEvent (org.springframework.context.ApplicationEvent event) { count++; System.out.println(event); }
|
||||
String getMessage() { return "count=" + count; }
|
||||
String getMessage() { return "count=" + count; }
|
||||
]]></lang:inline-script>
|
||||
</lang:bsh>
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
|
||||
<lang:groovy id="testBean" name="/url" script-source="classpath:org/springframework/scripting/config/TestBean.groovy"/>
|
||||
|
||||
<lang:groovy id="nonRefreshableTestBean" refresh-check-delay="-1"
|
||||
<lang:groovy id="nonRefreshableTestBean" refresh-check-delay="-1"
|
||||
script-source="classpath:org/springframework/scripting/config/TestBean.groovy"/>
|
||||
|
||||
<bean id="otherBean" class="org.springframework.scripting.config.OtherTestBean"/>
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
xmlns:lang="http://www.springframework.org/schema/lang"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/lang http://www.springframework.org/schema/lang/spring-lang-2.0.xsd">
|
||||
|
||||
<lang:groovy id="calculator"
|
||||
|
||||
<lang:groovy id="calculator"
|
||||
script-source="classpath:org/springframework/scripting/groovy/Calculator.groovy"
|
||||
customizer-ref="testCustomizer" />
|
||||
|
||||
|
|
|
|||
|
|
@ -11,14 +11,14 @@
|
|||
<constructor-arg>
|
||||
<bean class="org.springframework.scripting.groovy.GroovyScriptFactoryTests$TestCustomizer" />
|
||||
</constructor-arg>
|
||||
|
||||
|
||||
</bean>
|
||||
|
||||
<bean id="delegatingCalculator" class="org.springframework.scripting.groovy.GroovyScriptFactory">
|
||||
<constructor-arg value="classpath:org/springframework/scripting/groovy/DelegatingCalculator.groovy"/>
|
||||
|
||||
|
||||
<property name="delegate" ref="calculator"/>
|
||||
|
||||
|
||||
</bean>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
|
||||
http://www.springframework.org/schema/lang http://www.springframework.org/schema/lang/spring-lang-3.1.xsd">
|
||||
|
||||
|
||||
<lang:defaults proxy-target-class="true"/>
|
||||
|
||||
<lang:jruby id="refreshableMessenger" refresh-check-delay="1000"
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<!-- 'inline:' prefix is preceded by whitespace... -->
|
||||
<value>
|
||||
inline:
|
||||
|
||||
|
||||
class Bingo {
|
||||
|
||||
@Property String message;
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
def String message;
|
||||
}
|
||||
|
||||
|
||||
class Bingo {
|
||||
|
||||
def String message;
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
package org.springframework.scripting.groovy;
|
||||
|
||||
import org.springframework.scripting.Messenger;
|
||||
|
||||
|
||||
class Bingo {
|
||||
|
||||
@Property String message;
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ class RubyCalculatingMessenger
|
|||
def add(x, y)
|
||||
x + y
|
||||
end
|
||||
|
||||
|
||||
def setMessage(message)
|
||||
@@message = message
|
||||
end
|
||||
|
|
|
|||
|
|
@ -14,11 +14,11 @@ import org.springframework.scripting.Messenger
|
|||
class DelegatingMessenger implements Messenger {
|
||||
|
||||
private Messenger wrappedMessenger;
|
||||
|
||||
|
||||
public String getMessage() {
|
||||
this.wrappedMessenger.getMessage();
|
||||
}
|
||||
|
||||
|
||||
public void setMessenger(Messenger wrappedMessenger) {
|
||||
this.wrappedMessenger = wrappedMessenger;
|
||||
}
|
||||
|
|
@ -26,7 +26,7 @@ class DelegatingMessenger implements Messenger {
|
|||
</constructor-arg>
|
||||
<property name="messenger" ref="wrappedMessenger"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="wrappedMessenger" class="org.springframework.scripting.support.StubMessenger"/>
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -9,5 +9,5 @@
|
|||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql"/>
|
||||
<jdbc:script location="classpath*:org/springframework/jdbc/config/*-data.sql"/>
|
||||
</jdbc:embedded-database>
|
||||
|
||||
|
||||
</beans>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.1.xsd">
|
||||
|
||||
<jdbc:embedded-database id="dataSource" type="HSQL"/>
|
||||
|
||||
|
||||
<jdbc:initialize-database data-source="dataSource">
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql" execution="INIT"/>
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-test-data.sql" execution="INIT"/>
|
||||
|
|
|
|||
|
|
@ -6,14 +6,14 @@
|
|||
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.0.xsd">
|
||||
|
||||
<jdbc:embedded-database id="dataSource" type="HSQL"/>
|
||||
|
||||
|
||||
<jdbc:initialize-database data-source="dataSource">
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql"/>
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-test-data.sql"/>
|
||||
</jdbc:initialize-database>
|
||||
|
||||
<!-- This cache relies on data created in the initialize-database element. It works fine
|
||||
if the bean definitions are registered in the right order. (Could possibly be fixed later.) -->
|
||||
if the bean definitions are registered in the right order. (Could possibly be fixed later.) -->
|
||||
<bean class="org.springframework.jdbc.config.InitializeDatabaseIntegrationTests$CacheData">
|
||||
<property name="dataSource" ref="dataSource"/>
|
||||
</bean>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.0.xsd">
|
||||
|
||||
<jdbc:embedded-database id="dataSource" type="HSQL"/>
|
||||
|
||||
|
||||
<jdbc:initialize-database data-source="dataSource" enabled="#{systemProperties['ENABLED']}">
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql"/>
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-test-data.sql"/>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
<jdbc:script location="#{properties['schema.scripts']}" />
|
||||
<jdbc:script location="#{properties['insert.scripts']}" />
|
||||
</jdbc:initialize-database>
|
||||
|
||||
|
||||
<util:properties id="properties">
|
||||
<prop key="schema.scripts">classpath:org/springframework/jdbc/config/db-schema.sql</prop>
|
||||
<prop key="insert.scripts">classpath*:org/springframework/jdbc/config/*-data.sql</prop>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.0.xsd">
|
||||
|
||||
<jdbc:embedded-database id="dataSource" type="HSQL"/>
|
||||
|
||||
|
||||
<jdbc:initialize-database data-source="dataSource" ignore-failures="DROPS">
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-drops.sql"/>
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql"/>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.0.xsd">
|
||||
|
||||
<jdbc:embedded-database id="dataSource" type="HSQL"/>
|
||||
|
||||
|
||||
<jdbc:initialize-database data-source="dataSource">
|
||||
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql"/>
|
||||
<jdbc:script location="classpath*:org/springframework/jdbc/config/*-data.sql"/>
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue