|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.caleigo.toolkit.tunnel.ProxyHandler
| Field Summary | |
protected int |
mCurrentProxyID
|
protected java.util.Hashtable |
mProxyObjects
|
protected java.util.Hashtable |
mRemoteInvocationHandlers
|
protected ITunnel |
mTunnel
|
| Constructor Summary | |
ProxyHandler(ITunnel tunnel)
|
|
| Method Summary | |
boolean |
acceptsMessage(java.lang.Object message)
Returns true if this IMessageConsumer accepts the message.
|
java.lang.Object |
answerMessage(java.lang.Object message)
Tells the IMessageConsumer to consume a message and returns a new message that will be delivered to the sender of the originial message. |
void |
consumeMessage(java.lang.Object message)
Tells the IMessageConsumer to consume a message. |
java.lang.Object |
createProxy(java.lang.Class[] interfaceClasses,
java.lang.Object handler)
Creates a proxy for the provided interfaces. |
java.lang.Object |
createProxy(java.lang.Object obj)
Creates a proxy for all interfaces that the provided object and its superclasses implement. |
protected java.lang.reflect.Method |
findMatchingMethod(java.lang.Class targetClass,
java.lang.String methodName,
java.lang.Object[] arguments)
|
void |
finishProxy(java.lang.Object proxy)
|
protected int |
generateProxyID()
|
ITunnel |
getTunnel()
|
void |
registerRemoteInvocationHandler(java.lang.Class interfaceClass,
java.lang.Object handler)
Register an object that handles remote invokations for the provided interface. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected int mCurrentProxyID
protected ITunnel mTunnel
protected java.util.Hashtable mProxyObjects
protected java.util.Hashtable mRemoteInvocationHandlers
| Constructor Detail |
public ProxyHandler(ITunnel tunnel)
| Method Detail |
public java.lang.Object createProxy(java.lang.Object obj)
public java.lang.Object createProxy(java.lang.Class[] interfaceClasses,
java.lang.Object handler)
handler - object that will handle invocations on the created proxy.
The handler is allowed to be null in which
case invocation handlers must be registered for the
interfaces.public void finishProxy(java.lang.Object proxy)
public void registerRemoteInvocationHandler(java.lang.Class interfaceClass,
java.lang.Object handler)
public ITunnel getTunnel()
public boolean acceptsMessage(java.lang.Object message)
true if this IMessageConsumer accepts the message.
This method is allways called before consumeMessage for any
given message.
acceptsMessage in interface IMessageConsumerpublic void consumeMessage(java.lang.Object message)
consumeMessage in interface IMessageConsumerpublic java.lang.Object answerMessage(java.lang.Object message)
answerMessage in interface IMessageConsumerprotected int generateProxyID()
protected java.lang.reflect.Method findMatchingMethod(java.lang.Class targetClass,
java.lang.String methodName,
java.lang.Object[] arguments)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||