AI-MicroStructure
view release on metacpan or search on metacpan
Digest::SHA1: '0'
Exporter: '0'
Fcntl: '0'
File::Basename: '0'
File::Glob: '0'
File::HomeDir: '0'
File::Spec: '0'
Getopt::Long: '0'
HTML::SimpleLinkExtor: '0'
HTML::Strip: '0'
HTTP::Request::Common: '0'
IO::Async::Loop: '0'
IO::File: '0'
JSON: '0'
JSON::XS: '0'
LWP::UserAgent: '0'
Lingua::StopWords: '0'
List::Util: '0'
Mojolicious: '0'
Net::Async::WebSocket::Server: '0'
Parallel::Iterator: '0'
Makefile.PL view on Meta::CPAN
"Digest::SHA1" => 0,
"Exporter" => 0,
"Fcntl" => 0,
"File::Basename" => 0,
"File::Glob" => 0,
"File::HomeDir" => 0,
"File::Spec" => 0,
"Getopt::Long" => 0,
"HTML::SimpleLinkExtor" => 0,
"HTML::Strip" => 0,
"HTTP::Request::Common" => 0,
"IO::Async::Loop" => 0,
"IO::File" => 0,
"JSON" => 0,
"JSON::XS" => 0,
"LWP::UserAgent" => 0,
"Lingua::StopWords" => 0,
"List::Util" => 0,
"Mojolicious" => 0,
"Net::Async::WebSocket::Server" => 0,
"Parallel::Iterator" => 0,
Makefile.PL view on Meta::CPAN
"Digest::SHA1" => 0,
"Exporter" => 0,
"Fcntl" => 0,
"File::Basename" => 0,
"File::Glob" => 0,
"File::HomeDir" => 0,
"File::Spec" => 0,
"Getopt::Long" => 0,
"HTML::SimpleLinkExtor" => 0,
"HTML::Strip" => 0,
"HTTP::Request::Common" => 0,
"IO::Async::Loop" => 0,
"IO::File" => 0,
"JSON" => 0,
"JSON::XS" => 0,
"LWP::UserAgent" => 0,
"Lingua::StopWords" => 0,
"List::Util" => 0,
"Mojolicious" => 0,
"Net::Async::WebSocket::Server" => 0,
"Parallel::Iterator" => 0,
bin/remote.pl view on Meta::CPAN
if ($@) {
carp "LWP::UserAgent not available: $@";
return;
}
# fetch the content
my @items;
my @srcs = $class->sources($_[1]);
my $ua = LWP::UserAgent->new( env_proxy => 1 );
foreach my $src (@srcs) {
my $res = $ua->request( HTTP::Request->new( GET => $src ) );
if ( ! $res->is_success() ) {
carp "Failed to get content at $src (" . $res->status_line();
return;
}
# extract, cleanup and return the data
# if decoding the content fails, we just deal with the raw content
push @items =>
$class->extract( $res->decoded_content() || $res->content() );
Digest::MD5 = 0
Digest::SHA1 = 0
Exporter = 0
Fcntl = 0
File::Basename = 0
File::Glob = 0
File::Spec = 0
Getopt::Long = 0
HTML::SimpleLinkExtor = 0
HTML::Strip = 0
HTTP::Request::Common = 0
IO::Async::Loop = 0
IO::File = 0
JSON = 0
JSON::XS = 0
LWP::UserAgent = 0
Lingua::StopWords = 0
List::Util = 0
Net::Async::WebSocket::Server = 0
Parallel::Iterator = 0
Params::Validate = 0
lib/AI/MicroStructure/RemoteList.pm view on Meta::CPAN
}
# figure out the default category (for an instance)
my $category = ref $_[0] ? $_[1] || $_[0]->{category} : $_[1];
# fetch the content
my @items;
my @srcs = $class->sources($category);
my $ua = LWP::UserAgent->new( env_proxy => 1 );
foreach my $src (@srcs) {
my $request = HTTP::Request->new(
ref $src
? ( POST => $src->[0],
[ content_type => 'application/x-www-form-urlencoded' ],
$src->[1]
)
: ( GET => $src )
);
my $res = $ua->request( $request );
if ( ! $res->is_success() ) {
( run in 0.667 second using v1.01-cache-2.11-cpan-de7293f3b23 )