FurlX-Coro

 view release on metacpan or  search on metacpan

README.md  view on Meta::CPAN


This document describes FurlX::Coro version 1.01.

# SYNOPSIS

    use strict;
    use warnings;
    use Coro;
    use FurlX::Coro;

    my @coros;
    foreach my $url(@ARGV) {
        push @coros, async {
            print "fetching $url\n";
            my $ua  = FurlX::Coro->new();
            $ua->env_proxy();
            my $res = $ua->head($url);
            printf "%s: %s\n", $url, $res->status_line();
        }
    }

    $_->join for @coros;

# DESCRIPTION

This is a wrapper to `Furl` for asynchronous HTTP requests with `Coro`.

# INTERFACE

Interface is the same as `Furl`.

# DEPENDENCIES

example/http-ping.pl  view on Meta::CPAN

#!perl
use strict;
use warnings;
use Coro;
use FurlX::Coro;

my @coros;
foreach my $url(@ARGV) {
    push @coros, async {
        print "fetching $url\n";
        my $ua  = FurlX::Coro->new();
        $ua->env_proxy();
        my $res = $ua->head($url);
        printf "%s: %s\n", $url, $res->status_line();
    }
}

$_->join for @coros;

lib/FurlX/Coro.pm  view on Meta::CPAN


This document describes FurlX::Coro version 1.02.

=head1 SYNOPSIS

    use strict;
    use warnings;
    use Coro;
    use FurlX::Coro;

    my @coros;
    foreach my $url(@ARGV) {
        push @coros, async {
            print "fetching $url\n";
            my $ua  = FurlX::Coro->new();
            $ua->env_proxy();
            my $res = $ua->head($url);
            printf "%s: %s\n", $url, $res->status_line();
        }
    }

    $_->join for @coros;

=head1 DESCRIPTION

This is a wrapper to C<Furl> for asynchronous HTTP requests with C<Coro>.

=head1 INTERFACE

Interface is the same as C<Furl>.

=head1 DEPENDENCIES

lib/FurlX/Coro/HTTP.pm  view on Meta::CPAN

=head1 VERSION

This document describes FurlX::Coro version 1.02.

=head1 SYNOPSIS

    use FurlX::Coro::HTTP;

=head1 DESCRIPTION

FurlX::Coro::HTTP is a coro-friendly Furl::HTTP, which just uses Coro's C<select()> instead of the built-in one. The usage is completely the same as HTTP::Furl.

=head1 SEE ALSO

L<FurlX::Coro>

L<Furl::HTTP>

=cut



( run in 0.863 second using v1.01-cache-2.11-cpan-3cd7ad12f66 )