Logo Search packages:      
Sourcecode: paramiko version File versions  Download package

def paramiko::channel::Channel::close (   self  ) 

Close the channel.  All future read/write operations on the channel
will fail.  The remote end will receive no more data (after queued data
is flushed).  Channels are automatically closed when their L{Transport}
is closed or when they are garbage collected.

Definition at line 460 of file channel.py.

00460                    :
        """
        Close the channel.  All future read/write operations on the channel
        will fail.  The remote end will receive no more data (after queued data
        is flushed).  Channels are automatically closed when their L{Transport}
        is closed or when they are garbage collected.
        """
        self.lock.acquire()
        try:
            if not self.active or self.closed:
                return
            msgs = self._close_internal()

            # only close the pipe when the user explicitly closes the channel.
            # otherwise they will get unpleasant surprises.
            if self.pipe is not None:
                self.pipe.close()
                self.pipe = None
        finally:
            self.lock.release()
        for m in msgs:
            if m is not None:
                self.transport._send_user_message(m)

    def recv_ready(self):


Generated by  Doxygen 1.6.0   Back to index