Exception: Net::SSH::Simple::Error

Inherits:
RuntimeError
  • Object
show all
Defined in:
lib/net/ssh/simple.rb

Overview

Error that occured during a Net::SSH::Simple operation.

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (Error) initialize(msg, e = $!)

A new instance of Error



683
684
685
686
687
# File 'lib/net/ssh/simple.rb', line 683

def initialize(msg, e=$!)
  super(msg)
  @wrapped = e
  @result  = msg[1]
end

Instance Attribute Details

- (Object) result (readonly)

Result of the interrupted operation (may be incomplete!).



681
682
683
# File 'lib/net/ssh/simple.rb', line 681

def result
  @result
end

- (Object) wrapped (readonly)

Reference to the underlying Exception



678
679
680
# File 'lib/net/ssh/simple.rb', line 678

def wrapped
  @wrapped
end

Instance Method Details

- (Object) to_s



689
690
691
# File 'lib/net/ssh/simple.rb', line 689

def to_s
  "#{@wrapped} @ #{@result}"
end