|
JavaTM 2 Platform Std. Ed. v1.3.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
RemoteRef
represents the handle for a remote object. A
RemoteStub
uses a remote reference to carry out a
remote method invocation to a remote object.
RemoteStub
Field Summary | |
static String |
packagePrefix
Initialize the server package prefix: assumes that the implementation of server ref classes (e.g., UnicastRef, UnicastServerRef) are located in the package defined by the prefix. |
static long |
serialVersionUID
indicate compatibility with JDK 1.1.x version of class. |
Method Summary | |
void |
done(RemoteCall call)
Deprecated. 1.2 style stubs no longer use this method. Instead of using a sequence of method calls to the remote reference ( newCall , invoke , and done ), a
stub uses a single method, invoke(Remote, Method, Object[],
int) , on the remote reference to carry out parameter
marshalling, remote method executing and unmarshalling of the return
value.
1.2 stubs are generated using |
String |
getRefClass(ObjectOutput out)
Returns the class name of the ref type to be serialized onto the stream 'out'. |
void |
invoke(RemoteCall call)
Deprecated. 1.2 style stubs no longer use this method. Instead of using a sequence of method calls to the remote reference ( newCall , invoke , and done ), a
stub uses a single method, invoke(Remote, Method, Object[],
int) , on the remote reference to carry out parameter
marshalling, remote method executing and unmarshalling of the return
value.
1.2 stubs are generated using |
Object |
invoke(Remote obj,
Method method,
Object[] params,
long opnum)
Invoke a method. |
RemoteCall |
newCall(RemoteObject obj,
Operation[] op,
int opnum,
long hash)
Deprecated. 1.2 style stubs no longer use this method. Instead of using a sequence of method calls on the stub's the remote reference ( newCall , invoke , and done ), a
stub uses a single method, invoke(Remote, Method, Object[],
int) , on the remote reference to carry out parameter
marshalling, remote method executing and unmarshalling of the return
value.
1.2 stubs are generated using |
boolean |
remoteEquals(RemoteRef obj)
Compares two remote objects for equality. |
int |
remoteHashCode()
Returns a hashcode for a remote object. |
String |
remoteToString()
Returns a String that represents the reference of this remote object. |
Methods inherited from interface java.io.Externalizable |
readExternal, writeExternal |
Field Detail |
public static final long serialVersionUID
public static final String packagePrefix
Method Detail |
public Object invoke(Remote obj, Method method, Object[] params, long opnum) throws Exception
obj
- the object that contains the RemoteRef (e.g., the
RemoteStub for the object.method
- the method to be invokedparams
- the parameter listopnum
- a hash that may be used to represent the methodException
- if any exception occurs during remote method
invocationpublic RemoteCall newCall(RemoteObject obj, Operation[] op, int opnum, long hash) throws RemoteException
newCall
, invoke
, and done
), a
stub uses a single method, invoke(Remote, Method, Object[],
int)
, on the remote reference to carry out parameter
marshalling, remote method executing and unmarshalling of the return
value.
1.2 stubs are generated using rmic -v1.2
. By
default, rmic
generates stubs compatible with JDK1.1 and
the Java 2 SDK. The compatible stubs can also be generated using
rmic -vcompat
.
obj
- remote stub through which to make callop
- array of stub operationsopnum
- operation numberhash
- stub/skeleton interface hashRemoteException
- if failed to initiate new remote callinvoke(Remote,java.lang.reflect.Method,Object[],long)
public void invoke(RemoteCall call) throws Exception
newCall
, invoke
, and done
), a
stub uses a single method, invoke(Remote, Method, Object[],
int)
, on the remote reference to carry out parameter
marshalling, remote method executing and unmarshalling of the return
value.
1.2 stubs are generated using rmic -v1.2
. By
default, rmic
generates stubs compatible with JDK1.1 and
the Java 2 SDK. The compatible stubs can also be generated using
rmic -vcompat
.
call
- object representing remote callException
- if any exception occurs during remote methodinvoke(Remote,java.lang.reflect.Method,Object[],long)
public void done(RemoteCall call) throws RemoteException
newCall
, invoke
, and done
), a
stub uses a single method, invoke(Remote, Method, Object[],
int)
, on the remote reference to carry out parameter
marshalling, remote method executing and unmarshalling of the return
value.
1.2 stubs are generated using rmic -v1.2
. By
default, rmic
generates stubs compatible with JDK1.1 and
the Java 2 SDK. The compatible stubs can also be generated using rmic
-vcompat
.
call
- object representing remote callRemoteException
- if remote error occurs during call cleanupinvoke(Remote,java.lang.reflect.Method,Object[],long)
public String getRefClass(ObjectOutput out)
out
- the output stream to which the reference will be serializedpublic int remoteHashCode()
Hashtable
public boolean remoteEquals(RemoteRef obj)
obj
- the Object to compare withHashtable
public String remoteToString()
|
JavaTM 2 Platform Std. Ed. v1.3.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Java, Java 2D, and JDBC are trademarks or registered trademarks of Oracle and/or its affiliates, in the US and other countries.
Copyright © 1995, 2010 Oracle and/or its affiliates. All rights reserved.