Secure iNet Factory

com.jscape.inet.ssh.connection.channels
Class Channel

java.lang.Object
  extended by com.jscape.inet.ssh.connection.channels.Channel
Direct Known Subclasses:
SessionClient, TcpChannel, X11Client

public abstract class Channel
extends java.lang.Object

Version:
1.0
Author:
Natalya Okhremchuk

Nested Class Summary
static interface Channel.ChannelClosedListener
           
 class Channel.DataOutputStream
          The channel output stream.
static class Channel.Parameters
           
 
Method Summary
 void close()
           
 Connection getConnection()
           
 IncomingWindow getIncomingWindow()
          Get incoming window instance.
 java.io.InputStream getInputStream()
           
 long getLocalNo()
           
 java.io.OutputStream getOutputStream()
           
 Channel.Parameters getParameters()
           
 int getReadTimeout()
          Returns current read timeout value.
 long getRemoteNo()
           
 java.lang.String getType()
           
 int hashCode()
           
 boolean isClosed()
           
 void onMessage(Message message)
           
 void sendRequest(com.jscape.inet.ssh.connection.messages.SshMsgChannelRequest request)
           
 void setChannelClosedListener(Channel.ChannelClosedListener value)
           
 void setReadTimeout(int readTimeout)
          Setups new read timeout value.
 
Methods inherited from class java.lang.Object
equals, getClass, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getIncomingWindow

public IncomingWindow getIncomingWindow()
Get incoming window instance.

Returns:
window

getConnection

public Connection getConnection()
Returns:
connection

getParameters

public Channel.Parameters getParameters()
Returns:
parameters

getType

public java.lang.String getType()
Returns:
type

getLocalNo

public long getLocalNo()
Returns:
local number

getRemoteNo

public long getRemoteNo()
Returns:
remote number

sendRequest

public void sendRequest(com.jscape.inet.ssh.connection.messages.SshMsgChannelRequest request)
                 throws java.io.IOException
Parameters:
request -
Throws:
ConnectionException
java.io.IOException

getInputStream

public java.io.InputStream getInputStream()
Returns:
input stream

getOutputStream

public java.io.OutputStream getOutputStream()
Returns:
output stream

close

public void close()

isClosed

public boolean isClosed()
Returns:
closed

onMessage

public void onMessage(Message message)
Parameters:
message -

getReadTimeout

public int getReadTimeout()
Returns current read timeout value.

Returns:
current read timeout value

setReadTimeout

public void setReadTimeout(int readTimeout)
Setups new read timeout value.

Parameters:
readTimeout - read timeout value. Must be greater or equal to 0. In the last case means infinite value.

setChannelClosedListener

public void setChannelClosedListener(Channel.ChannelClosedListener value)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object
Returns:
hash code

Secure iNet Factory

Copyright © JSCAPE LLC. 1999-2011. All Rights Reserved