Package org.apache.activemq.wireformat
Class ObjectStreamWireFormat
- java.lang.Object
-
- org.apache.activemq.wireformat.ObjectStreamWireFormat
-
- All Implemented Interfaces:
WireFormat
public class ObjectStreamWireFormat extends Object implements WireFormat
A simple implementation which uses Object Stream serialization.
-
-
Constructor Summary
Constructors Constructor Description ObjectStreamWireFormat()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetVersion()ByteSequencemarshal(Object command)Packet based marshalingvoidmarshal(Object command, DataOutput ds)Stream based marshalingvoidsetVersion(int version)Objectunmarshal(DataInput ds)Packet based un-marshalingObjectunmarshal(ByteSequence packet)Packet based un-marshaling
-
-
-
Method Detail
-
marshal
public ByteSequence marshal(Object command) throws IOException
Description copied from interface:WireFormatPacket based marshaling- Specified by:
marshalin interfaceWireFormat- Throws:
IOException
-
unmarshal
public Object unmarshal(ByteSequence packet) throws IOException
Description copied from interface:WireFormatPacket based un-marshaling- Specified by:
unmarshalin interfaceWireFormat- Throws:
IOException
-
marshal
public void marshal(Object command, DataOutput ds) throws IOException
Description copied from interface:WireFormatStream based marshaling- Specified by:
marshalin interfaceWireFormat- Throws:
IOException
-
unmarshal
public Object unmarshal(DataInput ds) throws IOException
Description copied from interface:WireFormatPacket based un-marshaling- Specified by:
unmarshalin interfaceWireFormat- Throws:
IOException
-
setVersion
public void setVersion(int version)
- Specified by:
setVersionin interfaceWireFormat- Parameters:
version- the version of the wire format
-
getVersion
public int getVersion()
- Specified by:
getVersionin interfaceWireFormat- Returns:
- the version of the wire format
-
-