Class: Dupe::Sequence
- Inherits:
-
Object
- Object
- Dupe::Sequence
- Defined in:
- lib/dupe/sequence.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#initialize(start = 0) ⇒ Sequence
constructor
A new instance of Sequence.
- #next ⇒ Object
Constructor Details
#initialize(start = 0) ⇒ Sequence
Returns a new instance of Sequence.
3 4 5 |
# File 'lib/dupe/sequence.rb', line 3 def initialize(start=0) @sequence_value = start end |
Instance Method Details
#next ⇒ Object
7 8 9 |
# File 'lib/dupe/sequence.rb', line 7 def next @sequence_value += 1 end |