|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Allows instances implementing Packet to written to a DataOutput
Method Summary | |
boolean |
canWrite(Packet packet)
|
int |
getPacketType()
Return the type of Packet |
int |
getWireFormatVersion()
|
void |
setWireFormatVersion(int version)
Set the wire format version |
void |
writePacket(Packet packet,
DataOutput dataOut)
Write a Packet instance to data output stream |
byte[] |
writePacketToByteArray(Packet packet)
Serializes a Packet int a byte array |
Method Detail |
public int getPacketType()
public boolean canWrite(Packet packet)
packet
-
public void writePacket(Packet packet, DataOutput dataOut) throws IOException
packet
- the instance to be seralizeddataOut
- the output stream
IOException
- thrown if an error occurspublic byte[] writePacketToByteArray(Packet packet) throws IOException
packet
-
IOException
public void setWireFormatVersion(int version)
version
- public int getWireFormatVersion()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |