|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.rmi.server.RemoteObject java.rmi.server.RemoteServer java.rmi.server.UnicastRemoteObject net.sf.crispy.impl.rmi.RmiInvocationHandlerImpl
This is the central Invocation Handler for all client calls. You must register the service. The invoke methode make the call per reflection API.
Field Summary | |
protected static org.apache.commons.logging.Log |
log
|
Fields inherited from class java.rmi.server.RemoteObject |
ref |
Constructor Summary | |
RmiInvocationHandlerImpl()
|
Method Summary | |
void |
addService(java.lang.String pvServiceInterfaceName,
java.lang.Object pvServiceImpl)
Add service implementation. |
void |
addService(java.lang.String pvServiceInterfaceName,
java.lang.String pvServiceImplName)
Create a instance from the service impl class name. |
InterceptorHandler |
createNewInterceptorHandlerInstance()
Hint:Every call from this method must get a new instance from InterceptorHandler ! |
java.lang.Object |
doInvoke(java.lang.Object pvServiceImpl,
java.lang.reflect.Method pvMethod,
java.lang.Object[] pvArgs,
InterceptorHandler pvInterceptorHandler)
Execute the service with the InvocationHandler with delegate to doInvoke .
|
InterceptorHandlerCreator |
getInterceptorHandlerCreator()
Get a implementation for the interface InterceptorHandlerCreator . |
java.lang.Object |
getService(java.lang.String pvServiceInterfaceName)
Find the service impl. |
int |
getServiceSize()
Size of services in the container. |
java.lang.Object |
invoke(java.lang.String pvClassName,
java.lang.String pvMethodName,
java.util.Vector pvParams)
|
void |
removeService(java.lang.String pvServiceInterfaceName)
Remove the service from the container. |
void |
setInterceptorHandlerCreator(InterceptorHandlerCreator pvCreator)
Set a implementation for the interface InterceptorHandlerCreator . |
Methods inherited from class java.rmi.server.UnicastRemoteObject |
clone, exportObject, exportObject, exportObject, unexportObject |
Methods inherited from class java.rmi.server.RemoteServer |
getClientHost, getLog, setLog |
Methods inherited from class java.rmi.server.RemoteObject |
equals, getRef, hashCode, toString, toStub |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
protected static final org.apache.commons.logging.Log log
Constructor Detail |
public RmiInvocationHandlerImpl() throws java.rmi.RemoteException
Method Detail |
public java.lang.Object invoke(java.lang.String pvClassName, java.lang.String pvMethodName, java.util.Vector pvParams) throws java.rmi.RemoteException, java.lang.Exception
invoke
in interface RmiInvocationHandler
java.rmi.RemoteException
java.lang.Exception
RmiInvocationHandler.invoke(java.lang.String, java.lang.String, java.util.Vector)
public void addService(java.lang.String pvServiceInterfaceName, java.lang.Object pvServiceImpl)
SingleServiceContainer
addService
in interface SingleServiceContainer
pvServiceInterfaceName
- Is the key in a map.pvServiceImpl
- Is the value in a map.public void addService(java.lang.String pvServiceInterfaceName, java.lang.String pvServiceImplName)
SingleServiceContainer
addService
in interface SingleServiceContainer
pvServiceInterfaceName
- Is the key in a map.pvServiceImplName
- Is the class name from the service impl.public void removeService(java.lang.String pvServiceInterfaceName)
SingleServiceContainer
removeService
in interface SingleServiceContainer
pvServiceInterfaceName
- Is the key in a map.public java.lang.Object getService(java.lang.String pvServiceInterfaceName)
SingleServiceContainer
getService
in interface SingleServiceContainer
pvServiceInterfaceName
- Is the key in a map.
null
.public int getServiceSize()
SingleServiceContainer
getServiceSize
in interface SingleServiceContainer
public java.lang.Object doInvoke(java.lang.Object pvServiceImpl, java.lang.reflect.Method pvMethod, java.lang.Object[] pvArgs, InterceptorHandler pvInterceptorHandler)
ServiceEndpoint
InvocationHandler
with delegate to doInvoke
.
If parameter InterceptorHandler
is null
, then is calling the method createNewInterceptorHandlerInstance
,
else is using the parameter InterceptorHandler
.
doInvoke
in interface ServiceEndpoint
pvServiceImpl
- pvMethod
- pvArgs
- pvInterceptorHandler
-
public void setInterceptorHandlerCreator(InterceptorHandlerCreator pvCreator)
ServiceEndpoint
InterceptorHandlerCreator
. It is
equally with the method createNewInterceptorHandlerInstance
.
setInterceptorHandlerCreator
in interface ServiceEndpoint
pvCreator
- public InterceptorHandlerCreator getInterceptorHandlerCreator()
ServiceEndpoint
InterceptorHandlerCreator
.
getInterceptorHandlerCreator
in interface ServiceEndpoint
InterceptorHandlerCreator
implementation.public InterceptorHandler createNewInterceptorHandlerInstance()
ServiceEndpoint
InterceptorHandler
!
createNewInterceptorHandlerInstance
in interface ServiceEndpoint
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |