Exception: Rake::Funnel::ExecutionError
- Inherits:
-
StandardError
- Object
- StandardError
- Rake::Funnel::ExecutionError
- Defined in:
- lib/rake/funnel/execution_error.rb
Instance Attribute Summary collapse
-
#command ⇒ Object
readonly
Returns the value of attribute command.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#exit_code ⇒ Object
readonly
Returns the value of attribute exit_code.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
Instance Method Summary collapse
-
#initialize(command = nil, exit_code = nil, output = nil, description = nil) ⇒ ExecutionError
constructor
A new instance of ExecutionError.
- #to_s ⇒ Object
Constructor Details
#initialize(command = nil, exit_code = nil, output = nil, description = nil) ⇒ ExecutionError
Returns a new instance of ExecutionError.
6 7 8 9 10 11 12 13 |
# File 'lib/rake/funnel/execution_error.rb', line 6 def initialize(command = nil, exit_code = nil, output = nil, description = nil) super(description) @description = description @command = command @exit_code = exit_code @output = output end |
Instance Attribute Details
#command ⇒ Object (readonly)
Returns the value of attribute command.
4 5 6 |
# File 'lib/rake/funnel/execution_error.rb', line 4 def command @command end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
4 5 6 |
# File 'lib/rake/funnel/execution_error.rb', line 4 def description @description end |
#exit_code ⇒ Object (readonly)
Returns the value of attribute exit_code.
4 5 6 |
# File 'lib/rake/funnel/execution_error.rb', line 4 def exit_code @exit_code end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
4 5 6 |
# File 'lib/rake/funnel/execution_error.rb', line 4 def output @output end |
Instance Method Details
#to_s ⇒ Object
15 16 17 18 19 20 21 |
# File 'lib/rake/funnel/execution_error.rb', line 15 def to_s msg = [] << inspect_description << inspect_command << inspect_exit_code << last_output msg = msg.flatten.compact msg = [super.to_s] if msg.empty? msg.join("\n") end |