NAME

Handel::Iterator - Iterator class used for collection looping

SYNOPSIS

use Handel::Cart;

my $cart = Handel::Cart->new({
    shopper => 'D597DEED-5B9F-11D1-8DD2-00AA004ABD5E'
});

my $iterator = $cart->items;
while (my $item = $iterator->next) {
    print $item->sku;
    print $item->price;
    print $item->total;
};

DESCRIPTION

Handel::Iterator is used internally by Handel::Cart to iterate through collections of carts and cart items. At this point, there should be no reason to use it directly.

METHODS

all

Returns all results from the resultset as a list.

first

Returns the first result or undef if there are no results.

next

Returns the next result or undef if there are no results.

count

Returns the number of results.

reset

Resets the current result position back to the first result.

SEE ALSO

Handel::Cart

AUTHOR

Christopher H. Laco
CPAN ID: CLACO
claco@chrislaco.com
http://today.icantfocus.com/blog/