Class: SSHKit::Formatter::Abstract
- Inherits:
-
Object
- Object
- SSHKit::Formatter::Abstract
- Extended by:
- Forwardable
- Defined in:
- lib/sshkit/formatters/abstract.rb
Instance Attribute Summary collapse
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#original_output ⇒ Object
readonly
Returns the value of attribute original_output.
Instance Method Summary collapse
- #<<(obj) ⇒ Object
-
#initialize(output, options = {}) ⇒ Abstract
constructor
A new instance of Abstract.
- #log_command_data(command, _stream_type, _stream_data) ⇒ Object
- #log_command_exit(command) ⇒ Object
- #log_command_start(command) ⇒ Object
- #write(_obj) ⇒ Object
Constructor Details
Instance Attribute Details
#options ⇒ Object (readonly)
Returns the value of attribute options.
10 11 12 |
# File 'lib/sshkit/formatters/abstract.rb', line 10 def @options end |
#original_output ⇒ Object (readonly)
Returns the value of attribute original_output.
10 11 12 |
# File 'lib/sshkit/formatters/abstract.rb', line 10 def original_output @original_output end |
Instance Method Details
#<<(obj) ⇒ Object
39 40 41 |
# File 'lib/sshkit/formatters/abstract.rb', line 39 def <<(obj) write(obj) end |
#log_command_data(command, _stream_type, _stream_data) ⇒ Object
31 32 33 |
# File 'lib/sshkit/formatters/abstract.rb', line 31 def log_command_data(command, _stream_type, _stream_data) write(command) end |
#log_command_exit(command) ⇒ Object
35 36 37 |
# File 'lib/sshkit/formatters/abstract.rb', line 35 def log_command_exit(command) write(command) end |
#log_command_start(command) ⇒ Object
27 28 29 |
# File 'lib/sshkit/formatters/abstract.rb', line 27 def log_command_start(command) write(command) end |
#write(_obj) ⇒ Object
43 44 45 |
# File 'lib/sshkit/formatters/abstract.rb', line 43 def write(_obj) raise "Abstract formatter should not be used directly, maybe you want SSHKit::Formatter::BlackHole" end |