Class: Approvals::Executable
- Inherits:
-
Object
- Object
- Approvals::Executable
- Defined in:
- lib/approvals/executable.rb
Instance Attribute Summary collapse
-
#command ⇒ Object
Returns the value of attribute command.
-
#on_failure ⇒ Object
Returns the value of attribute on_failure.
Instance Method Summary collapse
-
#initialize(command, &block) ⇒ Executable
constructor
A new instance of Executable.
- #inspect ⇒ Object
- #to_s ⇒ Object
Constructor Details
permalink #initialize(command, &block) ⇒ Executable
Returns a new instance of Executable.
5 6 7 8 |
# File 'lib/approvals/executable.rb', line 5 def initialize(command, &block) self.command = command self.on_failure = block end |
Instance Attribute Details
permalink #command ⇒ Object
Returns the value of attribute command.
4 5 6 |
# File 'lib/approvals/executable.rb', line 4 def command @command end |
permalink #on_failure ⇒ Object
Returns the value of attribute on_failure.
4 5 6 |
# File 'lib/approvals/executable.rb', line 4 def on_failure @on_failure end |
Instance Method Details
permalink #inspect ⇒ Object
[View source]
14 15 16 |
# File 'lib/approvals/executable.rb', line 14 def inspect command end |
permalink #to_s ⇒ Object
[View source]
10 11 12 |
# File 'lib/approvals/executable.rb', line 10 def to_s inspect end |