Class Channel

java.lang.Object
com.jcraft.jsch.Channel
All Implemented Interfaces:
Runnable
Direct Known Subclasses:
ChannelAgentForwarding, ChannelDirectTCPIP, ChannelForwardedTCPIP, ChannelSession, ChannelX11

public abstract class Channel extends Object implements Runnable
  • Field Details

    • SSH_MSG_CHANNEL_OPEN_CONFIRMATION

      static final int SSH_MSG_CHANNEL_OPEN_CONFIRMATION
      See Also:
    • SSH_MSG_CHANNEL_OPEN_FAILURE

      static final int SSH_MSG_CHANNEL_OPEN_FAILURE
      See Also:
    • SSH_MSG_CHANNEL_WINDOW_ADJUST

      static final int SSH_MSG_CHANNEL_WINDOW_ADJUST
      See Also:
    • SSH_OPEN_ADMINISTRATIVELY_PROHIBITED

      static final int SSH_OPEN_ADMINISTRATIVELY_PROHIBITED
      See Also:
    • SSH_OPEN_CONNECT_FAILED

      static final int SSH_OPEN_CONNECT_FAILED
      See Also:
    • SSH_OPEN_UNKNOWN_CHANNEL_TYPE

      static final int SSH_OPEN_UNKNOWN_CHANNEL_TYPE
      See Also:
    • SSH_OPEN_RESOURCE_SHORTAGE

      static final int SSH_OPEN_RESOURCE_SHORTAGE
      See Also:
    • index

      static int index
    • pool

      private static Vector pool
    • id

      int id
    • recipient

      volatile int recipient
    • type

      protected byte[] type
    • lwsize_max

      volatile int lwsize_max
    • lwsize

      volatile int lwsize
    • lmpsize

      volatile int lmpsize
    • rwsize

      volatile long rwsize
    • rmpsize

      volatile int rmpsize
    • io

      IO io
    • thread

      Thread thread
    • eof_local

      volatile boolean eof_local
    • eof_remote

      volatile boolean eof_remote
    • close

      volatile boolean close
    • connected

      volatile boolean connected
    • open_confirmation

      volatile boolean open_confirmation
    • exitstatus

      volatile int exitstatus
    • reply

      volatile int reply
    • connectTimeout

      volatile int connectTimeout
    • session

      private Session session
    • notifyme

      int notifyme
  • Constructor Details

    • Channel

      Channel()
  • Method Details

    • getChannel

      static Channel getChannel(String type)
    • getChannel

      static Channel getChannel(int id, Session session)
    • del

      static void del(Channel c)
    • setRecipient

      void setRecipient(int foo)
    • getRecipient

      int getRecipient()
    • init

      void init() throws JSchException
      Throws:
      JSchException
    • connect

      public void connect() throws JSchException
      Throws:
      JSchException
    • connect

      public void connect(int connectTimeout) throws JSchException
      Throws:
      JSchException
    • setXForwarding

      public void setXForwarding(boolean foo)
    • start

      public void start() throws JSchException
      Throws:
      JSchException
    • isEOF

      public boolean isEOF()
    • getData

      void getData(Buffer buf)
    • setInputStream

      public void setInputStream(InputStream in)
    • setInputStream

      public void setInputStream(InputStream in, boolean dontclose)
    • setOutputStream

      public void setOutputStream(OutputStream out)
    • setOutputStream

      public void setOutputStream(OutputStream out, boolean dontclose)
    • setExtOutputStream

      public void setExtOutputStream(OutputStream out)
    • setExtOutputStream

      public void setExtOutputStream(OutputStream out, boolean dontclose)
    • getInputStream

      public InputStream getInputStream() throws IOException
      Throws:
      IOException
    • getExtInputStream

      public InputStream getExtInputStream() throws IOException
      Throws:
      IOException
    • getOutputStream

      public OutputStream getOutputStream() throws IOException
      Throws:
      IOException
    • setLocalWindowSizeMax

      void setLocalWindowSizeMax(int foo)
    • setLocalWindowSize

      void setLocalWindowSize(int foo)
    • setLocalPacketSize

      void setLocalPacketSize(int foo)
    • setRemoteWindowSize

      void setRemoteWindowSize(long foo)
    • addRemoteWindowSize

      void addRemoteWindowSize(long foo)
    • setRemotePacketSize

      void setRemotePacketSize(int foo)
    • run

      public void run()
      Specified by:
      run in interface Runnable
    • write

      void write(byte[] foo) throws IOException
      Throws:
      IOException
    • write

      void write(byte[] foo, int s, int l) throws IOException
      Throws:
      IOException
    • write_ext

      void write_ext(byte[] foo, int s, int l) throws IOException
      Throws:
      IOException
    • eof_remote

      void eof_remote()
    • eof

      void eof()
    • close

      void close()
    • isClosed

      public boolean isClosed()
    • disconnect

      static void disconnect(Session session)
    • disconnect

      public void disconnect()
    • isConnected

      public boolean isConnected()
    • sendSignal

      public void sendSignal(String signal) throws Exception
      Throws:
      Exception
    • setExitStatus

      void setExitStatus(int status)
    • getExitStatus

      public int getExitStatus()
    • setSession

      void setSession(Session session)
    • getSession

      public Session getSession() throws JSchException
      Throws:
      JSchException
    • getId

      public int getId()
    • sendOpenConfirmation

      protected void sendOpenConfirmation() throws Exception
      Throws:
      Exception
    • sendOpenFailure

      protected void sendOpenFailure(int reasoncode)
    • genChannelOpenPacket

      protected Packet genChannelOpenPacket()
    • sendChannelOpen

      protected void sendChannelOpen() throws Exception
      Throws:
      Exception