Method: Net::SSH::Connection::Channel#active?
- Defined in:
- lib/net/ssh/connection/channel.rb
#active? ⇒ Boolean
Returns true if the channel exists in the channel list of the session, and false otherwise. This can be used to determine whether a channel has been closed or not.
ssh.loop { channel.active? }
259 260 261 |
# File 'lib/net/ssh/connection/channel.rb', line 259 def active? connection.channels.key?(local_id) end |