Method: Puppet::Pops::Types::StepIterator#initialize

Defined in:
lib/puppet/pops/types/iterable.rb

#initialize(element_type, enumeration, step_size) ⇒ StepIterator

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of StepIterator.

Raises:

  • (ArgumentError)


290
291
292
293
294
295
# File 'lib/puppet/pops/types/iterable.rb', line 290

def initialize(element_type, enumeration, step_size)
  super(element_type, enumeration)
  raise ArgumentError if step_size <= 0

  @step_size = step_size
end