|
Préférences
Moteurs de recherche
|
||||||||||||||
JavaTM 2 Platform Std. Ed. v1.6.0
java.rmi
|
Constructor Summary | |
---|---|
MarshalledObject(T obj)
Creates a new MarshalledObject that contains the
serialized representation of the current state of the supplied object. |
Method Summary | |
---|---|
boolean |
equals(Object obj)
Compares this MarshalledObject to another object. |
T |
get()
Returns a new copy of the contained marshalledobject. |
int |
hashCode()
Return a hash code for this MarshalledObject . |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MarshalledObject(T obj) throws IOException
MarshalledObject
that contains the
serialized representation of the current state of the supplied object.
The object is serialized with the semantics used for marshaling
parameters for RMI calls.
obj
- the object to be serialized (must be serializable)
IOException
- if an IOException
occurs; an
IOException
may occur if obj
is not
serializable.Method Detail |
---|
public T get() throws IOException, ClassNotFoundException
IOException
- if an IOException
occurs while
deserializing the object from its internal representation.
ClassNotFoundException
- if a
ClassNotFoundException
occurs while deserializing the
object from its internal representation.
could not be foundpublic int hashCode()
MarshalledObject
.
Object.equals(java.lang.Object)
,
Hashtable
public boolean equals(Object obj)
MarshalledObject
to another object.
Returns true if and only if the argument refers to a
MarshalledObject
that contains exactly the same
serialized representation of an object as this one does. The
comparison ignores any class codebase annotation, meaning that
two objects are equivalent if they have the same serialized
representation except for the codebase of each class
in the serialized representation.
obj
- the object to compare with this MarshalledObject
true
if the argument contains an equaivalent
serialized object; false
otherwiseObject.hashCode()
,
Hashtable