Class: Nrename::Counter

Inherits:
Object
  • Object
show all
Defined in:
lib/nrename/counter.rb

Instance Method Summary collapse

Constructor Details

#initializeCounter

Returns a new instance of Counter.



3
4
5
# File 'lib/nrename/counter.rb', line 3

def initialize
  @counter = 0
end

Instance Method Details

#nextObject



7
8
9
# File 'lib/nrename/counter.rb', line 7

def next
  @counter = @counter.next
end