java.lang.Object | |||
↳ | java.io.OutputStream | ||
↳ | java.io.ObjectOutputStream | ||
↳ | sun.rmi.server.MarshalOutputStream |
A MarshalOutputStream extends ObjectOutputStream to add functions specific to marshaling of remote object references. If it is necessary to serialize remote objects or objects that contain references to remote objects a MarshalOutputStream must be used instead of ObjectOutputStream.
A new MarshalOutputStream is constructed to serialize remote objects or graphs containing remote objects. Objects are written to the stream using the ObjectOutputStream.writeObject method.
MarshalOutputStream maps remote objects to the corresponding remote stub and embeds the location from which to load the stub classes. The location may be ignored by the client but is supplied.
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a marshal output stream with protocol version 1.
| |||||||||||
Creates a marshal output stream with the given protocol version.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Serializes a location from which to load the the specified class.
| |||||||||||
Serializes a location from which to load the specified class.
| |||||||||||
Checks for objects that are instances of java.rmi.Remote
that need to be serialized as proxy objects.
| |||||||||||
Writes the location for the class into the stream.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() |
Creates a marshal output stream with protocol version 1.
IOException |
---|
Creates a marshal output stream with the given protocol version.
IOException |
---|
Serializes a location from which to load the the specified class.
cl | the class to annotate custom data for |
---|
IOException |
---|
Serializes a location from which to load the specified class.
cl | the proxy class to annotate custom data for |
---|
IOException |
---|
Checks for objects that are instances of java.rmi.Remote that need to be serialized as proxy objects.
obj | the object to be replaced |
---|
IOException |
---|
Writes the location for the class into the stream. This method can be overridden by subclasses that store this annotation somewhere else than as the next object in the stream, as is done by this class.
IOException |
---|