|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuka.karmi.rmi.server.RemoteStub
Base class for remote stubs. Stub objects are remote references
to server implementation objects on a remote machine. This abstract
class RemoteStub is extended by concrete stub classes
that are generated by the stub and skeleton generator.
A generated stub class implements a stub method for each method
of a server implementation object declared in its Remote
interface. This stub method is responsible for forwarding the call
to the remote node by marshaling the method arguments, unmarshaling
the result, and returning the result value to its calle.
A generated stub method performs the following actions:
ClientConnection object
is requested from the underlying RemoteClientRef object.ClientConnection.openSendCall() is called on the
connection object for transmission of the call header. ClientConnection.closeSendCall() is called to indicate
that the call is prepared completely and can now be processed from
the server machine. ClientConnection.openReceiveResult() is called. This
call blocks until the result is available form the server. The
result value indicated, whether the remote method completed
normally, or if an exception was thrown. ClientConnection.closeReceiveResult() is called on the
connection to indicated that the remote invocation is complete and
the connection can be reused for further remote calls to the same
destination. Stubs delegate the hashCode() and equals(Object) methods to their RemoteClientRef.
RemoteClientRef.getContext(int),
ClientConnection,
ClientConnection.openSendCall(),
ClientConnection.closeSendCall(),
ClientConnection.openReceiveResult(),
ClientConnection.closeReceiveResult(),
Serialized Form| Field Summary | |
static int |
ID_LASTMETHOD
There is no method defined by default that can be invoked remotely. |
protected RemoteClientRef |
remoteClientRef
See BUG/0020 |
| Constructor Summary | |
RemoteStub()
Default contructor, transportable classes have no implicit default constructor. |
|
| Method Summary | |
protected static int |
_KARMI_getLastMethodID()
Export the last method id to the super classes of this stub class to check the generation of unique method ids within a branch in the class hierarchy. |
RemoteClientRef |
_KARMI_getRemoteClientRef()
See BUG/0020 |
void |
_KARMI_setRemoteClientRef(RemoteClientRef remoteClientRef)
See BUG/0020 |
protected abstract void |
_KARMI_setRemoteServer(Remote server)
Implemented in generated stub class. |
java.lang.String |
_KARMI_toStringMembers()
|
boolean |
equals(java.lang.Object obj)
|
java.lang.Object |
getOwner()
Return the root object this object belongs to. |
int |
hashCode()
|
private void |
readObject(java.io.ObjectInputStream s)
Updates this stub object after unmarshaling it from an ObjectInputStream. |
private void |
restoreAfterUnmarshal()
Just declare exceptions that are never thrown and forward the call to silentRestoreAfterUnmarshal(). |
private void |
silentRestoreAfterUnmarshal()
Updates this stub, after unmarshaling. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected RemoteClientRef remoteClientRef
public static final int ID_LASTMETHOD
| Constructor Detail |
public RemoteStub()
| Method Detail |
public final RemoteClientRef _KARMI_getRemoteClientRef()
public final void _KARMI_setRemoteClientRef(RemoteClientRef remoteClientRef)
protected abstract void _KARMI_setRemoteServer(Remote server)
protected static int _KARMI_getLastMethodID()
private void silentRestoreAfterUnmarshal()
UnmarshalStream. It is called from readObject(java.io.ObjectInputStream), if it is unmarshaled through an ObjectInputStream.
private void restoreAfterUnmarshal()
throws java.io.IOException,
java.lang.ClassNotFoundException
silentRestoreAfterUnmarshal(). This is because
the declaration of these exceptions is required for
restoreAfterUnmarshal() methods according to the uka.transport
specification.
java.io.IOException
java.lang.ClassNotFoundException
private void readObject(java.io.ObjectInputStream s)
throws java.io.IOException,
java.lang.ClassNotFoundException
ObjectInputStream.
java.io.IOException
java.lang.ClassNotFoundExceptionpublic int hashCode()
Object.hashCode()public boolean equals(java.lang.Object obj)
public final java.lang.Object getOwner()
PatchableRootPatchableRoot, if the PatchableRoot.getOwner() method returns
another object than the current replicated object.
getOwner in interface PatchableRootPatchableRoot.getOwner()public java.lang.String _KARMI_toStringMembers()
public java.lang.String toString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||