public abstract class WithSerialId extends java.lang.Object
Base class for objects which can be exposed to remote nodes via serialization.
Main concept is following:
See java.io.Serializable for detailed description how methods writeReplace & readResolve works.
It is very important to know that (de)serialization never happens by itself but always happens in context of groovyx.gpars.remote.RemoteHost and (
Modifiers | Name | Description |
---|---|---|
SerialHandle |
serialHandle |
See SerialHandle class for details |
private static long |
serialVersionUID |
Constructor and description |
---|
WithSerialId
() |
Type | Name and description |
---|---|
protected RemoteHandle |
createRemoteHandle(SerialHandle handle, SerialContext host) |
SerialHandle |
getOrCreateSerialHandle() Gets serial handle for the object If needed new handle created and serialization host subscribed for the object handle |
java.lang.Class<T> |
getRemoteClass() Class of remote object to be created |
protected java.lang.Object |
writeReplace() Replace object by handle for serialization |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(), java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
See SerialHandle class for details
Gets serial handle for the object If needed new handle created and serialization host subscribed for the object handle
Class of remote object to be created
Replace object by handle for serialization
Copyright © 2008–2014 Václav Pech. All Rights Reserved.