THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Code Block | ||||
---|---|---|---|---|
| ||||
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd"> <beans> <bean id="shoppingCart" class="org.springframework.aop.target.scope.ScopedProxyFactoryBean" singleton="false"> <property name="scopeKey" value="shoppingCart"/> <property name="targetBeanName" value="__shoppingCart"/> <property name="scopeMap"> <bean class="org.springframework.web.context.scope.SessionScopeMap"/> </property> </bean> <bean id="__shoppingCart" class="com.opensymphony.webwork.example.ajax.cart.DefaultCart" singleton="false"/> </beans> {code:xml} A modified |
A modified applicationContext.xml
...
for
...
the
...
shopping
...
cart
...
example
...
using
...
the
...
XML
...
simplification
...
is
...
below.
Code Block | ||||
---|---|---|---|---|
| ||||
{code:xml}<?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd"> <bean id="catalog" class="com.opensymphony.webwork.example.ajax.catalog.TestCatalog" singleton="true"/> <bean id="shoppingCart" class="com.opensymphony.webwork.example.ajax.cart.DefaultCart"> <aop:scope type="session"/> </bean> </beans> |
...