com.sshtools.j2ssh.connection
Class SshMsgChannelOpenFailure

java.lang.Object
  |
  +--com.sshtools.j2ssh.transport.SshMessage
        |
        +--com.sshtools.j2ssh.connection.SshMsgChannelOpenFailure

public class SshMsgChannelOpenFailure
extends SshMessage

Implements the SSH_MSG_CHANNEL_OPEN_FAILURE message.

Version:
1.0
Author:
Lee David Painter ( lee@sshtools.com )

Field Summary
protected static int SSH_MSG_CHANNEL_OPEN_FAILURE
          The message id
protected static long SSH_OPEN_ADMINISTRATIVELY_PROHIBITED
          A Channel Failure Reason Code
protected static long SSH_OPEN_CONNECT_FAILED
          A Channel Failure Reason Code
protected static long SSH_OPEN_RESOURCE_SHORTAGE
          A Channel Failure Reason Code
protected static long SSH_OPEN_UNKNOWN_CHANNEL_TYPE
          A Channel Failure Reason Code
 
Constructor Summary
SshMsgChannelOpenFailure()
          Constructor for the SshMsgChannelOpenFailure object
SshMsgChannelOpenFailure(long recipientChannel, long reasonCode, java.lang.String additional, java.lang.String languageTag)
          Constructor for the SshMsgChannelOpenFailure object
 
Method Summary
protected  void constructByteArray(ByteArrayWriter baw)
          Abstract method implementation to construct a byte array containing the message.
protected  void constructMessage(ByteArrayReader bar)
          Abstract method implementation to construct the message from a byte array.
 java.lang.String getAdditionalText()
          Gets the additional text
 java.lang.String getLanguageTag()
          Gets the language tag
 java.lang.String getMessageName()
          Gets the message name for debugging
 long getReasonCode()
          Gets the reason code
 long getRecipientChannel()
          Gets the recipient channel id
 
Methods inherited from class com.sshtools.j2ssh.transport.SshMessage
fromByteArray, getMessageId, toByteArray
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SSH_MSG_CHANNEL_OPEN_FAILURE

protected static final int SSH_MSG_CHANNEL_OPEN_FAILURE
The message id

See Also:
Constant Field Values

SSH_OPEN_ADMINISTRATIVELY_PROHIBITED

protected static final long SSH_OPEN_ADMINISTRATIVELY_PROHIBITED
A Channel Failure Reason Code

See Also:
Constant Field Values

SSH_OPEN_CONNECT_FAILED

protected static final long SSH_OPEN_CONNECT_FAILED
A Channel Failure Reason Code

See Also:
Constant Field Values

SSH_OPEN_UNKNOWN_CHANNEL_TYPE

protected static final long SSH_OPEN_UNKNOWN_CHANNEL_TYPE
A Channel Failure Reason Code

See Also:
Constant Field Values

SSH_OPEN_RESOURCE_SHORTAGE

protected static final long SSH_OPEN_RESOURCE_SHORTAGE
A Channel Failure Reason Code

See Also:
Constant Field Values
Constructor Detail

SshMsgChannelOpenFailure

public SshMsgChannelOpenFailure(long recipientChannel,
                                long reasonCode,
                                java.lang.String additional,
                                java.lang.String languageTag)
Constructor for the SshMsgChannelOpenFailure object

Parameters:
recipientChannel - The recipient channel id
reasonCode - The reason code for the failure
additional - Additional textual information
languageTag - The language tag

SshMsgChannelOpenFailure

public SshMsgChannelOpenFailure()
Constructor for the SshMsgChannelOpenFailure object

Method Detail

getMessageName

public java.lang.String getMessageName()
Gets the message name for debugging

Specified by:
getMessageName in class SshMessage
Returns:

getRecipientChannel

public long getRecipientChannel()
Gets the recipient channel id

Returns:
The recipient channel id

getReasonCode

public long getReasonCode()
Gets the reason code

Returns:
The reason code

getAdditionalText

public java.lang.String getAdditionalText()
Gets the additional text

Returns:
The additional text

getLanguageTag

public java.lang.String getLanguageTag()
Gets the language tag

Returns:
The language tag

constructMessage

protected void constructMessage(ByteArrayReader bar)
                         throws InvalidMessageException
Abstract method implementation to construct the message from a byte array.

Specified by:
constructMessage in class SshMessage
Parameters:
bar - The byte array being read
Throws:
InvalidMessageException - Thrown if the data cannot be read

constructByteArray

protected void constructByteArray(ByteArrayWriter baw)
                           throws InvalidMessageException
Abstract method implementation to construct a byte array containing the message.

Specified by:
constructByteArray in class SshMessage
Parameters:
baw - The byte array being written
Throws:
InvalidMessageException - Thrown if the data cannot be written


Copyright © 2002 Sshtools.com. All Rights Reserved.