1 package org
.argeo
.slc
.executionflow
;
3 import org
.apache
.commons
.logging
.Log
;
4 import org
.apache
.commons
.logging
.LogFactory
;
5 import org
.springframework
.aop
.TargetSource
;
7 public class ExecutionTargetSource
implements TargetSource
{
8 private final static Log log
= LogFactory
9 .getLog(ExecutionTargetSource
.class);
12 private Class targetClass
;
14 public Object
getTarget() throws Exception
{
15 if (log
.isTraceEnabled())
16 log
.trace("Getting object " + name
);
17 ExecutionFlow executionFlow
= SimpleExecutionFlow
18 .getCurrentExecutionFlow();
19 Object obj
= executionFlow
.getAttributes().get(name
);
20 if (log
.isTraceEnabled())
21 log
.trace("Target object " + obj
);
25 public Class
getTargetClass() {
29 public boolean isStatic() {
33 public void releaseTarget(Object target
) throws Exception
{
34 // TODO Auto-generated method stub
38 public void setName(String name
) {
42 public void setTargetClass(Class targetClass
) {
43 this.targetClass
= targetClass
;