|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.proxy.Interceptor org.jboss.invocation.InvokerInterceptor
A very simple implementation of it that branches to the local stuff.
Field Summary | |
protected static Invoker |
localInvoker
Static references to local invokers. |
protected Invoker |
remoteInvoker
Invoker to the remote JMX node. |
Fields inherited from class org.jboss.proxy.Interceptor |
nextInterceptor |
Constructor Summary | |
InvokerInterceptor()
Exposed for externalization. |
Method Summary | |
static Invoker |
getLocal()
Get the local invoker reference, useful for optimization. |
Object |
invoke(Invocation invocation)
The invocation on the delegate, calls the right invoker. |
protected Object |
invokeInvoker(Invocation invocation)
Invoke using invoker |
protected Object |
invokeLocal(Invocation invocation)
Invoke using local invoker |
protected Object |
invokeMarshalled(Invocation invocation)
Invoke using local invoker and marshalled |
boolean |
isLocal()
Returns wether we are local to the originating container or not. |
boolean |
isLocal(Invocation invocation)
Whether the target is local |
void |
readExternal(ObjectInput in)
Un-externalize this instance. |
static void |
setLocal(Invoker invoker)
Set the local invoker reference, useful for optimization. |
void |
writeExternal(ObjectOutput out)
Externalize this instance. |
Methods inherited from class org.jboss.proxy.Interceptor |
getNext, setNext |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected Invoker remoteInvoker
protected static Invoker localInvoker
Constructor Detail |
public InvokerInterceptor()
Method Detail |
public static Invoker getLocal()
public static void setLocal(Invoker invoker)
public boolean isLocal()
public boolean isLocal(Invocation invocation)
invocation
- the invocation
public Object invoke(Invocation invocation) throws Exception
invoke
in class Interceptor
Exception
protected Object invokeLocal(Invocation invocation) throws Exception
invocation
- the invocation
Exception
- for any errorprotected Object invokeMarshalled(Invocation invocation) throws Exception
invocation
- the invocation
Exception
- for any errorprotected Object invokeInvoker(Invocation invocation) throws Exception
invocation
- the invocation
Exception
- for any errorpublic void writeExternal(ObjectOutput out) throws IOException
If this instance lives in a different VM than its container invoker, the remote interface of the container invoker is not externalized.
writeExternal
in interface Externalizable
writeExternal
in class Interceptor
IOException
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
We check timestamps of the interfaces to see if the instance is in the original VM of creation
readExternal
in interface Externalizable
readExternal
in class Interceptor
IOException
ClassNotFoundException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |