T
- The header type for this gc message.public abstract class GCMsgBase<T extends IGCSerializableHeader> extends AMsgBase implements IClientGCMsg
Modifier and Type | Field and Description |
---|---|
private T |
header
Gets the header for this message type.
|
private boolean |
isProto
true if this instance is protobuf backed; otherwise, false
|
private int |
msgType
The network message type.
|
JobID |
sourceJobID
The source job id.
|
JobID |
targetJobID
The target job id.
|
Constructor and Description |
---|
GCMsgBase(Class<T> clazz,
int payloadReserve)
Initializes a new instance of the
GCMsgBase class. |
Modifier and Type | Method and Description |
---|---|
abstract void |
deSerialize(byte[] data)
Initializes this client message by deserializing the specified data.
|
abstract byte[] |
serialize()
serializes this client message instance to a byte array.
|
write, write, write, write, writeNullTermString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getMsgType, getSourceJobID, getTargetJobID, isProto, setSourceJobID, setTargetJobID
private boolean isProto
private int msgType
public JobID targetJobID
public JobID sourceJobID
private T extends IGCSerializableHeader header
public abstract byte[] serialize() throws IOException
serialize
in interface IClientGCMsg
IOException
public abstract void deSerialize(byte[] data) throws IOException
deSerialize
in interface IClientGCMsg
data
- The data representing a client message.IOException
Copyright © 2012. All Rights Reserved.