Package paramiko :: Class Channel
[show private | hide private]
[frames | no frames]

Class Channel

object --+    
         |    
   Channel --+
             |
            Channel


A secure tunnel across an SSH Transport. A Channel is meant to behave like a socket, and has an API that should be indistinguishable from the python socket API.
Method Summary
    Inherited from Channel
  __init__(self, chanid)
string __repr__(self)
Returns a string representation of this object, for debugging.
  check_pty_request(self, term, width, height, pixelwidth, pixelheight, modes)
override me! return True if a pty of the given dimensions (for shell access, usually) can be provided
  check_shell_request(self)
override me! return True if shell access will be provided
  check_subsystem_request(self, name)
override me! return True if the given subsystem can be provided
  check_window_change_request(self, width, height, pixelwidth, pixelheight)
override me! return True if the pty was resized
  close(self)
Close the channel.
  exec_command(self, command)
int fileno(self)
Returns an OS-level file descriptor which can be used for polling and reading (but not for writing).
string get_name(self)
Get the name of this channel that was previously set by set_name.
  get_pty(self, term, width, height)
Request a pseudo-terminal from the server.
Transport get_transport(self)
Return the Transport associated with this channel.
float gettimeout(self)
Returns the timeout in seconds (as a float) associated with socket operations, or None if no timeout is set.
  invoke_shell(self)
  invoke_subsystem(self, subsystem)
ChannelFile makefile(self, *params)
Return a file-like object associated with this channel, without the non-portable side effects of fileno.
string recv(self, nbytes)
Receive data from the channel.
boolean recv_ready(self)
Returns true if data is ready to be read from this channel.
  resize_pty(self, width, height)
Resize the pseudo-terminal.
int send(self, s)
Send data to the channel.
  sendall(self, s)
Send data to the channel, without allowing partial results.
  set_name(self, name)
Set a name for this channel.
  setblocking(self, blocking)
Set blocking or non-blocking mode of the channel: if blocking is 0, the channel is set to non-blocking mode; otherwise it's set to blocking mode.
  settimeout(self, timeout)
Set a timeout on blocking read/write operations.
  shutdown(self, how)
Shut down one or both halves of the connection.
  _check_add_window(self, n)
  _feed(self, m)
  _feed_pipe(self, data)
you are already holding the lock
  _handle_close(self, m)
  _handle_eof(self, m)
  _handle_request(self, m)
  _log(self, level, msg)
  _push_pipe(self, nbytes)
  _read_pipe(self, nbytes)
you are already holding the lock
  _request_failed(self, m)
  _request_success(self, m)
  _send_eof(self)
  _set_remote_channel(self, chanid, window_size, max_packet_size)
  _set_transport(self, transport)
  _set_window(self, window_size, max_packet_size)
  _unlink(self)
  _window_adjust(self, m)
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value
  __str__(x)
x.__str__() <==> str(x)
    Inherited from type
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T

Generated by Epydoc 2.0 on Sat Jan 3 19:20:24 2004 http://epydoc.sf.net