01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
03: */
04: package com.tc.object.config;
05:
06: import com.tc.aspectwerkz.DeploymentModel;
07: import com.tc.aspectwerkz.definition.deployer.AspectDefinitionBuilder;
08: import com.tc.aspectwerkz.definition.deployer.AspectModule;
09: import com.tc.aspectwerkz.definition.deployer.AspectModuleDeployer;
10:
11: /**
12: * Manages deployment of all AW aspects used for Spring WebFlow support
13: *
14: * @author Eugene Kuleshov
15: */
16: public class SpringWebFlowAspectModule implements AspectModule {
17:
18: public void deploy(final AspectModuleDeployer deployer) {
19: buildDefinitionForConversationLockProtocol(deployer);
20: }
21:
22: private void buildDefinitionForConversationLockProtocol(
23: AspectModuleDeployer deployer) {
24: AspectDefinitionBuilder builder = deployer.newAspectBuilder(
25: "com.tcspring.ConversationLockProtocol",
26: DeploymentModel.PER_JVM, null);
27:
28: builder
29: .addAdvice(
30: "around",
31: "execution(* org.springframework.webflow.conversation.impl.ConversationLockFactory.createLock())",
32: "replaceUtilConversationLock(StaticJoinPoint jp)");
33: }
34:
35: }
|