JML

net.sf.jml.protocol
Class MsnMessage

java.lang.Object
  extended by net.sf.jml.protocol.MsnMessage
Direct Known Subclasses:
MsnftpMessage, MsnIncomingMessage, MsnOutgoingMessage

public abstract class MsnMessage
extends Object

MSN Message. See: http://www.hypothetic.org/docs/msn/general/commands.php

Author:
Roger Chen

Field Summary
protected  MsnProtocol protocol
           
 
Constructor Summary
protected MsnMessage(MsnProtocol protocol)
           
 
Method Summary
protected  void addParam(String s)
           
 String asString()
           
protected  void clearParams()
           
protected  byte[] getChunkData()
           
 String getCommand()
           
protected  String getParam(int index)
           
protected  int getParamCount()
           
 MsnProtocol getProtocol()
           
 int getTransactionId()
           
protected  boolean isSupportChunkData()
          If support chunk data, then can set chunk data.
protected  boolean isSupportTransactionId()
          If support transaction id, then can set transaction id.
protected  boolean load(ByteBuffer buffer)
           
protected  ByteBuffer[] save()
           
protected  void setChunkData(byte[] chunkData)
           
protected  void setChunkData(String chunkData)
           
protected  void setCommand(String command)
           
protected  void setParam(int index, String s)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

protocol

protected final MsnProtocol protocol
Constructor Detail

MsnMessage

protected MsnMessage(MsnProtocol protocol)
Method Detail

getProtocol

public final MsnProtocol getProtocol()

getTransactionId

public final int getTransactionId()

getCommand

public final String getCommand()

isSupportTransactionId

protected boolean isSupportTransactionId()
If support transaction id, then can set transaction id.

Returns:
is support transaction id

setCommand

protected final void setCommand(String command)

getParam

protected final String getParam(int index)

getParamCount

protected final int getParamCount()

setParam

protected final void setParam(int index,
                              String s)

addParam

protected final void addParam(String s)

clearParams

protected final void clearParams()

isSupportChunkData

protected boolean isSupportChunkData()
If support chunk data, then can set chunk data.

Returns:
is support chunk data

getChunkData

protected final byte[] getChunkData()

setChunkData

protected final void setChunkData(byte[] chunkData)

setChunkData

protected final void setChunkData(String chunkData)

load

protected boolean load(ByteBuffer buffer)

save

protected ByteBuffer[] save()

toString

public String toString()
Overrides:
toString in class Object

asString

public String asString()

JML