ist.palcom.mal
Class SimpleMessage

java.lang.Object
  extended by ist.palcom.mal.Message
      extended by ist.palcom.mal.SimpleMessage

public class SimpleMessage
extends Message


Field Summary
static byte TYPE_DATA
           
 
Fields inherited from class ist.palcom.mal.Message
TYPE_MULTIPART, TYPE_NONE, TYPE_SINGLE
 
Constructor Summary
SimpleMessage(byte[] information)
           
SimpleMessage(byte[] information, int offset, int informationLength)
           
SimpleMessage(byte type, byte[] information, int offset, int informationLength)
           
 
Method Summary
 Message getCopy()
           
 byte[] getInformation()
           
 int getInformationLength()
           
 byte getType()
          Returns the data type of the message.
protected  int writeInformation(byte[] buffer, int offset)
           
 
Methods inherited from class ist.palcom.mal.Message
addPart, getData, getDataLength, getHeaderNodes, getHeaderNodesLength, getNodeAndDataLength, getNumberOfParts, getPart, getRawData, getReceiverDeviceID, getReceiverSelector, getReceiverURL, getSenderDeviceID, getSenderSelector, getSenderURL, getTotalLength, insertHeaderNodeAfter, insertHeaderNodeFirst, insertHeaderNodeLast, parse, removePart, setData, setHeaderNodes, setReceiverDeviceID, setReceiverSelector, setReceiverURL, setSenderDeviceID, setSenderSelector, setSenderURL, write, writeData, writeDataNodeToBuffer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_DATA

public static final byte TYPE_DATA
See Also:
Constant Field Values
Constructor Detail

SimpleMessage

public SimpleMessage(byte[] information)

SimpleMessage

public SimpleMessage(byte[] information,
                     int offset,
                     int informationLength)

SimpleMessage

public SimpleMessage(byte type,
                     byte[] information,
                     int offset,
                     int informationLength)
Method Detail

getInformationLength

public int getInformationLength()

getInformation

public byte[] getInformation()

getType

public byte getType()
Description copied from class: Message
Returns the data type of the message.

Overrides:
getType in class Message

writeInformation

protected int writeInformation(byte[] buffer,
                               int offset)

getCopy

public Message getCopy()
Overrides:
getCopy in class Message
Returns:
A copy of the message, with the same data in new buffer(s).