org.activeio.command
Interface WireFormat

All Known Implementing Classes:
DefaultWireFormat

public interface WireFormat

Provides a mechanism to marshal commands into and out of packets or into and out of streams, Channels and Datagrams.

Version:
$Revision: 1.1 $

Method Summary
 int getVersion()
           
 Packet marshal(Object command)
          Packet based marshaling
 void marshal(Object command, DataOutputStream out)
          Stream based marshaling
 void setVersion(int version)
           
 Object unmarshal(DataInputStream in)
          Packet based un-marshaling
 Object unmarshal(Packet packet)
          Packet based un-marshaling
 

Method Detail

marshal

public Packet marshal(Object command)
               throws IOException
Packet based marshaling

Throws:
IOException

unmarshal

public Object unmarshal(Packet packet)
                 throws IOException
Packet based un-marshaling

Throws:
IOException

marshal

public void marshal(Object command,
                    DataOutputStream out)
             throws IOException
Stream based marshaling

Throws:
IOException

unmarshal

public Object unmarshal(DataInputStream in)
                 throws IOException
Packet based un-marshaling

Throws:
IOException

setVersion

public void setVersion(int version)

getVersion

public int getVersion()
Returns:
the version of the wire format


Copyright © -2007 The ActiveIO Project. All Rights Reserved.