Class: CommandIssuer::CommandResult
- Inherits:
-
Object
- Object
- CommandIssuer::CommandResult
- Defined in:
- lib/get/commons/command_issuer.rb
Overview
A class containing the result of a command, including the exit status and the command executed.
Instance Attribute Summary collapse
-
#command ⇒ Object
readonly
Returns the value of attribute command.
-
#error ⇒ Object
readonly
Returns the value of attribute error.
-
#exit_status ⇒ Object
readonly
Returns the value of attribute exit_status.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
Instance Method Summary collapse
-
#initialize(command_string, exit_status, standard_output, standard_error) ⇒ CommandResult
constructor
A new instance of CommandResult.
Constructor Details
#initialize(command_string, exit_status, standard_output, standard_error) ⇒ CommandResult
Returns a new instance of CommandResult.
28 29 30 31 32 33 |
# File 'lib/get/commons/command_issuer.rb', line 28 def initialize(command_string, exit_status, standard_output, standard_error) @command = command_string @exit_status = exit_status @output = standard_output @error = standard_error end |
Instance Attribute Details
#command ⇒ Object (readonly)
Returns the value of attribute command.
26 27 28 |
# File 'lib/get/commons/command_issuer.rb', line 26 def command @command end |
#error ⇒ Object (readonly)
Returns the value of attribute error.
26 27 28 |
# File 'lib/get/commons/command_issuer.rb', line 26 def error @error end |
#exit_status ⇒ Object (readonly)
Returns the value of attribute exit_status.
26 27 28 |
# File 'lib/get/commons/command_issuer.rb', line 26 def exit_status @exit_status end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
26 27 28 |
# File 'lib/get/commons/command_issuer.rb', line 26 def output @output end |