Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
make array from iterator using coderef
Perl
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib/Iterator
t
.gitignore
.travis.yml
Build.PL
Changes
LICENSE
META.json
README.md
cpanfile
minil.toml

README.md

NAME

Iterator::ToArray - create array or arrayref from iterator

SYNOPSIS

use Iterator::ToArray qw/to_array/;


my $iterator = Your::Iterator->new();

# OO style
my $to_array = Iterator::ToArray->new($iterator);
my $coderef  = sub { $_ * $_ };
my $array = $to_array->apply($coderef);

# function style
my $array    = to_array $iter, sub { $_* $_ };

DESCRIPTION

Iterator::ToArray convert iterator to array using coderef.

AUTHOR

Yoshihiro Sasaki

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

Something went wrong with that request. Please try again.