Class: StageBase
- Inherits:
-
Object
- Object
- StageBase
- Defined in:
- lib/asker/ai/problem/stage_base.rb
Direct Known Subclasses
Instance Method Summary collapse
- #counter ⇒ Object
- #customize ⇒ Object
-
#initialize(problem) ⇒ StageBase
constructor
A new instance of StageBase.
Constructor Details
#initialize(problem) ⇒ StageBase
Returns a new instance of StageBase.
5 6 7 8 9 10 |
# File 'lib/asker/ai/problem/stage_base.rb', line 5 def initialize(problem) @problem = problem @customs = get_customs(@problem) @customizer = Customizer.new(@problem) @counter = @problem.questions.size end |
Instance Method Details
#counter ⇒ Object
12 13 14 |
# File 'lib/asker/ai/problem/stage_base.rb', line 12 def counter @counter += 1 end |
#customize ⇒ Object
16 17 18 |
# File 'lib/asker/ai/problem/stage_base.rb', line 16 def customize(...) @customizer.call(...) end |