Class: Checkout::Runner
- Inherits:
-
Object
- Object
- Checkout::Runner
- Defined in:
- lib/checkout/runner.rb
Instance Attribute Summary collapse
-
#branch ⇒ Object
Returns the value of attribute branch.
-
#branch_choice_object ⇒ Object
writeonly
Sets the attribute branch_choice_object.
-
#branches ⇒ Object
writeonly
Sets the attribute branches.
-
#max ⇒ Object
Returns the value of attribute max.
-
#selection ⇒ Object
Returns the value of attribute selection.
Instance Method Summary collapse
-
#initialize(max) ⇒ Runner
constructor
A new instance of Runner.
- #run! ⇒ Object
Constructor Details
#initialize(max) ⇒ Runner
Returns a new instance of Runner.
7 8 9 10 |
# File 'lib/checkout/runner.rb', line 7 def initialize(max) get_max(max) run! end |
Instance Attribute Details
#branch ⇒ Object
Returns the value of attribute branch.
5 6 7 |
# File 'lib/checkout/runner.rb', line 5 def branch @branch end |
#branch_choice_object=(value) ⇒ Object
Sets the attribute branch_choice_object
5 6 7 |
# File 'lib/checkout/runner.rb', line 5 def branch_choice_object=(value) @branch_choice_object = value end |
#branches=(value) ⇒ Object
Sets the attribute branches
5 6 7 |
# File 'lib/checkout/runner.rb', line 5 def branches=(value) @branches = value end |
#max ⇒ Object
Returns the value of attribute max.
5 6 7 |
# File 'lib/checkout/runner.rb', line 5 def max @max end |
#selection ⇒ Object
Returns the value of attribute selection.
5 6 7 |
# File 'lib/checkout/runner.rb', line 5 def selection @selection end |
Instance Method Details
#run! ⇒ Object
12 13 14 15 16 |
# File 'lib/checkout/runner.rb', line 12 def run! ask_for_selection map_selection_to_branch checkout end |