Class: Interact::Progress::Skipper
- Inherits:
-
Object
- Object
- Interact::Progress::Skipper
- Defined in:
- lib/interact/progress.rb
Instance Method Summary collapse
- #fail(&callback) ⇒ Object
- #give_up(&callback) ⇒ Object
-
#initialize(&ret) ⇒ Skipper
constructor
A new instance of Skipper.
- #skip(&callback) ⇒ Object
Constructor Details
#initialize(&ret) ⇒ Skipper
Returns a new instance of Skipper.
60 61 62 |
# File 'lib/interact/progress.rb', line 60 def initialize(&ret) @return = ret end |
Instance Method Details
#fail(&callback) ⇒ Object
72 73 74 |
# File 'lib/interact/progress.rb', line 72 def fail(&callback) @return.call("FAILED", :error, callback) end |
#give_up(&callback) ⇒ Object
68 69 70 |
# File 'lib/interact/progress.rb', line 68 def give_up(&callback) @return.call("GAVE UP", :bad, callback) end |
#skip(&callback) ⇒ Object
64 65 66 |
# File 'lib/interact/progress.rb', line 64 def skip(&callback) @return.call("SKIPPED", :warning, callback) end |