JML

net.sf.jml.protocol.msnslp
Class MsnslpMessage

java.lang.Object
  extended by net.sf.jml.protocol.msnslp.MsnslpMessage
All Implemented Interfaces:
net.sf.cindy.Message
Direct Known Subclasses:
MsnslpRequest, MsnslpResponse

public abstract class MsnslpMessage
extends Object
implements net.sf.cindy.Message

MSNSLP message. See http://zoronax.bot2k3.net/msn6/msnp9/msnslp_p2p.html and http://siebe.bot2k3.net/docs/?url=msnslp.html

Author:
Roger Chen

Field Summary
protected  StringHolder bodys
           
protected  StringHolder headers
           
 
Constructor Summary
MsnslpMessage()
           
 
Method Summary
 String getBody()
           
 StringHolder getBodys()
           
 String getCallId()
           
 String getContentType()
           
 int getCSeq()
           
 String getFrom()
           
 StringHolder getHeaders()
           
 int getMajorVersion()
           
 int getMaxForwards()
           
 int getMinorVersion()
           
 String getTo()
           
 String getVia()
           
protected abstract  boolean readFirstLine(String firstLine)
           
 boolean readFromBuffer(ByteBuffer buffer)
           
 void setBody(String body)
           
 void setCallId(String callId)
           
 void setContentType(String contentType)
           
 void setCSeq(int cseq)
           
 void setFrom(String from)
           
 void setMajorVersion(int majorVersion)
           
 void setMaxForwards(int maxForwards)
           
 void setMinorVersion(int minorVersion)
           
 void setTo(String to)
           
 void setVia(String via)
           
 ByteBuffer[] toByteBuffer()
           
 String toString()
           
protected abstract  void writeFirstLine(StringBuffer buffer)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

headers

protected final StringHolder headers

bodys

protected final StringHolder bodys
Constructor Detail

MsnslpMessage

public MsnslpMessage()
Method Detail

getMajorVersion

public final int getMajorVersion()

setMajorVersion

public final void setMajorVersion(int majorVersion)

getMinorVersion

public final int getMinorVersion()

setMinorVersion

public final void setMinorVersion(int minorVersion)

getHeaders

public final StringHolder getHeaders()

getBodys

public final StringHolder getBodys()

setTo

public final void setTo(String to)

getTo

public final String getTo()

setFrom

public final void setFrom(String from)

getFrom

public final String getFrom()

setVia

public final void setVia(String via)

getVia

public final String getVia()

setCSeq

public final void setCSeq(int cseq)

getCSeq

public final int getCSeq()

setCallId

public final void setCallId(String callId)

getCallId

public final String getCallId()

setMaxForwards

public final void setMaxForwards(int maxForwards)

getMaxForwards

public final int getMaxForwards()

setContentType

public final void setContentType(String contentType)

getContentType

public final String getContentType()

getBody

public final String getBody()

setBody

public final void setBody(String body)

toString

public final String toString()
Overrides:
toString in class Object

toByteBuffer

public ByteBuffer[] toByteBuffer()
Specified by:
toByteBuffer in interface net.sf.cindy.Message

readFromBuffer

public boolean readFromBuffer(ByteBuffer buffer)
Specified by:
readFromBuffer in interface net.sf.cindy.Message

readFirstLine

protected abstract boolean readFirstLine(String firstLine)

writeFirstLine

protected abstract void writeFirstLine(StringBuffer buffer)

JML