org.jboss.aop.joinpoint
Class MethodInvocationWrapper
java.lang.Object
org.jboss.aop.joinpoint.InvocationBase
org.jboss.aop.joinpoint.MethodInvocation
org.jboss.aop.joinpoint.MethodInvocationWrapper
- All Implemented Interfaces:
- Externalizable, Invocation, Serializable
- public class MethodInvocationWrapper
- extends MethodInvocation
This wrapper class allows you to insert a chain of interceptors into the middle of a call stack.
- Version:
- $Revision: 1.11 $
- Author:
- Bill Burke
- See Also:
- Serialized Form
MethodInvocationWrapper
public MethodInvocationWrapper(MethodInvocation wrapped,
Interceptor[] interceptors)
getMetaData
public Object getMetaData(Object group,
Object attr)
- Description copied from class:
MethodInvocation
- This method resolves metadata based on the context of the invocation.
It iterates through its list of MetaDataResolvers to find out the
value of the metadata desired.
This list usually is ThreadMetaData, InstanceAdvisor.getMetaData
ClassAdvisor.getMethodMetaData (or field, or constructor)
ClassAdvisor.getDefaultMetaData
- Specified by:
getMetaData
in interface Invocation
- Overrides:
getMetaData
in class MethodInvocation
invokeNext
public Object invokeNext()
throws Throwable
- Description copied from class:
MethodInvocation
- Invoke on the next interceptor in the chain. If this is already
the end of the chain, reflection will call the constructor, field, or
method you are invoking on.
- Specified by:
invokeNext
in interface Invocation
- Overrides:
invokeNext
in class MethodInvocation
- Throws:
Throwable
getInstanceResolver
public MetaDataResolver getInstanceResolver()
- Overrides:
getInstanceResolver
in class InvocationBase
getArguments
public Object[] getArguments()
- Overrides:
getArguments
in class MethodInvocation
setArguments
public void setArguments(Object[] args)
- Overrides:
setArguments
in class MethodInvocation
getTargetObject
public Object getTargetObject()
- Specified by:
getTargetObject
in interface Invocation
- Overrides:
getTargetObject
in class InvocationBase
copy
public Invocation copy()
- Description copied from class:
MethodInvocation
- Copies complete state of Invocation object.
- Specified by:
copy
in interface Invocation
- Overrides:
copy
in class MethodInvocation
- Returns:
getMethod
public Method getMethod()
- Overrides:
getMethod
in class MethodInvocation
getActualMethod
public Method getActualMethod()
- Overrides:
getActualMethod
in class MethodInvocation
getMethodHash
public long getMethodHash()
- Overrides:
getMethodHash
in class MethodInvocation
getAdvisor
public Advisor getAdvisor()
- Specified by:
getAdvisor
in interface Invocation
- Overrides:
getAdvisor
in class MethodInvocation
getResponseContextInfo
public Map getResponseContextInfo()
- Specified by:
getResponseContextInfo
in interface Invocation
- Overrides:
getResponseContextInfo
in class InvocationBase
setResponseContextInfo
public void setResponseContextInfo(Map responseContextInfo)
- Specified by:
setResponseContextInfo
in interface Invocation
- Overrides:
setResponseContextInfo
in class InvocationBase
getResponseAttachment
public Object getResponseAttachment(Object key)
- Specified by:
getResponseAttachment
in interface Invocation
- Overrides:
getResponseAttachment
in class InvocationBase
addResponseAttachment
public void addResponseAttachment(Object key,
Object val)
- Specified by:
addResponseAttachment
in interface Invocation
- Overrides:
addResponseAttachment
in class InvocationBase
getMetaData
public SimpleMetaData getMetaData()
- Description copied from class:
InvocationBase
- Return all the contextual data attached to this invocation
- Specified by:
getMetaData
in interface Invocation
- Overrides:
getMetaData
in class InvocationBase
setMetaData
public void setMetaData(SimpleMetaData data)
- Description copied from class:
InvocationBase
- Set all the contextual data attached to this invocation
- Specified by:
setMetaData
in interface Invocation
- Overrides:
setMetaData
in class InvocationBase
setTargetObject
public void setTargetObject(Object targetObject)
- Specified by:
setTargetObject
in interface Invocation
- Overrides:
setTargetObject
in class InvocationBase
Copyright © 2004 JBoss Inc. All Rights Reserved.