class TOMMessage extends SystemMessage implements Externalizable, Comparable, Cloneable {

	public void wExternal(DataOutput out) throws IOException {
		out.writeInt(sender);
		out.writeInt(viewID);
		out.writeInt(type.toInt());
		out.writeInt(session);
		out.writeInt(sequence);
		out.writeInt(operationId);
		out.writeInt(replyServer);

		if (content == null) {
			out.writeInt(-1);
		} else {
			out.writeInt(content.length);
			out.write(content);
		}
	}

	public  TOMMessage();
	public  TOMMessage(int sender, int session, int sequence, byte[] content, int view, TOMMessageType type);
	public  TOMMessage(int sender, int session, int sequence, int operationId, byte[] content, int view,
			TOMMessageType type);

}