|
Secure iNet Factory | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jscape.inet.ssh.transport.Message
com.jscape.inet.ssh.transport.messages.SshMsgDisconnect
public final class SshMsgDisconnect
Disconnection message: SSH_MSG_DISCONNECT. This message causes immediate termination of the connection. The sender must not send or receive any data after this message, and the recipient must not accept any data after receiving this message. The description field gives a more specific explanation in a human-readable form. The error code gives the reason in a more machine-readable format.
Field Summary | |
---|---|
static int |
TYPE
Message type code. |
Constructor Summary | |
---|---|
SshMsgDisconnect(long reasonCode,
java.lang.String description,
java.lang.String languageTag)
Creates a new message instance. |
Method Summary | |
---|---|
boolean |
accept(TransportMessageDispatcher dispatcher)
Calls an appropriate dispatcher method. |
java.lang.String |
getDescription()
Returns the disconnect reason description. |
java.lang.String |
getLanguageTag()
Returns the description language tag. |
long |
getReasonCode()
Returns the disconnect reason code. |
static SshMsgDisconnect |
readFrom(java.io.InputStream in)
|
static Message |
readFrom(SshReader reader)
Reads the message from the reader. |
java.lang.String |
toString()
Returns the string representation of this message. |
void |
writeTo(java.io.OutputStream out)
|
void |
writeTo(SshWriter writer)
Writes the message to the specified writer. |
Methods inherited from class com.jscape.inet.ssh.transport.Message |
---|
getId, getType, readFrom, readFrom, setId |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int TYPE
Constructor Detail |
---|
public SshMsgDisconnect(long reasonCode, java.lang.String description, java.lang.String languageTag)
reasonCode
- the disconnect reason codedescription
- the reason descriptionlanguageTag
- the description language tagMethod Detail |
---|
public static SshMsgDisconnect readFrom(java.io.InputStream in) throws java.io.IOException
in
-
java.io.IOException
public static Message readFrom(SshReader reader) throws java.io.IOException
reader
- the SSH types reader
java.io.IOException
- if an I/O error occurspublic long getReasonCode()
public java.lang.String getDescription()
public java.lang.String getLanguageTag()
public void writeTo(java.io.OutputStream out) throws java.io.IOException
writeTo
in class Message
out
-
java.io.IOException
public void writeTo(SshWriter writer) throws java.io.IOException
writeTo
in class Message
writer
- the SSH types writer
java.io.IOException
- if an I/O error occurspublic boolean accept(TransportMessageDispatcher dispatcher)
accept
in interface TransportDispatchable
dispatcher
- the message dispatcher
true
if dispatcher can dispatch this message;
false
otherwisepublic java.lang.String toString()
toString
in class java.lang.Object
|
Secure iNet Factory | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |