|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sapia.ubik.rmi.server.RemoteRef
public abstract class RemoteRef
This class implements the basic behavior of dynamic proxies that implement the logic for performing RPC on remote objects.
| Field Summary | |
|---|---|
protected boolean |
_callBack
|
protected boolean |
_isFirstVoyage
|
protected java.lang.Object |
_lock
|
protected OID |
_oid
|
protected Connections |
_pool
|
protected ServerAddress |
_serverAddress
|
protected VmId |
_vmId
|
| Constructor Summary | |
|---|---|
RemoteRef()
|
|
RemoteRef(OID oid,
ServerAddress serverAddress)
Creates an instance of this class, with the given object and host identifiers. |
|
| Method Summary | |
|---|---|
OID |
getOid()
Returns this instance's object identifier. |
OID |
getOID()
Returns the identifier of the remote object to which this instance corresponds. |
ServerAddress |
getServerAddress()
Returns the address of the server to which this stub "belongs". |
protected void |
initPool(boolean force)
|
abstract java.lang.Object |
invoke(java.lang.Object obj,
java.lang.reflect.Method toCall,
java.lang.Object[] params)
|
boolean |
isCallBack()
Returns true if this stub is in call-back mode. |
boolean |
isValid()
Tests the connection between this handler and its server; returns false if connection is invalid. |
void |
readExternal(java.io.ObjectInput in)
|
protected java.lang.Object |
sendCommand(RMICommand cmd)
|
protected void |
setCallBack(boolean callBack)
Sets this stub's call-back mode. |
StubContainer |
toStubContainer(java.lang.Object proxy)
Returns this instance's stub container. |
void |
writeExternal(java.io.ObjectOutput out)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected boolean _callBack
protected OID _oid
protected VmId _vmId
protected ServerAddress _serverAddress
protected boolean _isFirstVoyage
protected transient Connections _pool
protected transient java.lang.Object _lock
| Constructor Detail |
|---|
public RemoteRef()
public RemoteRef(OID oid,
ServerAddress serverAddress)
oid - an OIDserverAddress - a ServerAddress| Method Detail |
|---|
public boolean isCallBack()
true if this stub is in call-back mode.
true if this stub is in call-back mode.public OID getOID()
getOID in interface StubInvocationHandlerOID.protected void setCallBack(boolean callBack)
callBack - must be true if this stub should
be in call-back mode.
public abstract java.lang.Object invoke(java.lang.Object obj,
java.lang.reflect.Method toCall,
java.lang.Object[] params)
throws java.lang.Throwable
invoke in interface java.lang.reflect.InvocationHandlerjava.lang.ThrowableInvocationHandler.invoke(Object, Method, Object[])public ServerAddress getServerAddress()
ServerAddresspublic OID getOid()
OIDpublic boolean isValid()
isValid in interface HealthCheckfalse if connection is invalid.public StubContainer toStubContainer(java.lang.Object proxy)
StubInvocationHandler
toStubContainer in interface StubInvocationHandlerStubContainerStubInvocationHandler.toStubContainer(Object)
public void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
readExternal in interface java.io.Externalizablejava.io.IOException
java.lang.ClassNotFoundExceptionExternalizable.readExternal(ObjectInput)
public void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
writeExternal in interface java.io.Externalizablejava.io.IOExceptionExternalizable.writeExternal(ObjectOutput)
protected java.lang.Object sendCommand(RMICommand cmd)
throws java.lang.Throwable
java.lang.Throwable
protected void initPool(boolean force)
throws java.rmi.RemoteException
java.rmi.RemoteException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||