NAME

Salvation::MacroProcessor::Iterator::Compliance - Salvation::MacroProcessor::Iterator-compatible iterator interface

REQUIRES

Moose

METHODS

Following methods should be implemented by a class in order to be compatible with Salvation::MacroProcessor::Iterator.

first

$object -> first()

Returns first element of a list.

last

$object -> last()

Returns last element of a list.

seek

$object -> seek( $position )

Sets position of an iterator to $position.

next

$object -> next()

Returns element at current position, then increases position by one.

count

$object -> count()

Returns elements count.

to_start

$object -> to_start()

Sets position of an iterator to start.

to_end

$object -> to_end()

Sets position of an iterator to end.

__position

$object -> __position()

Returns current position of an iterator.

prev

$object -> prev()

Returns element at current position, then decreases position by one.