| CPAN-Search-Lite documentation | view source | Contained in the CPAN-Search-Lite distribution. |
$info->{dists}version - the version of the CPAN filefilename - the CPAN filenamecpanid - the CPAN author iddescription - a description, if availablesize - the size of the filedate - the last modified date (YYYY/MM/DD) of the filemd5 - the CPAN md5 checksum of the filemodules - specifies the modules present in the distribution:chapterid - specifies the chapterid and the subchapter
for the distribution:requires - a hash reference whose keys are the names of
prerequisite modules required for the package and whose values are
the associated module versions. This information comes from the
META.yml file processed in CPAN::Search::Lite::Extract.
$info->{mods}$info->{auths}CPAN::Search::Lite::Info - extract information from CPAN indices
This module extracts information from the CPAN indices
$CPAN/indices/ls-lR.gz, $CPAN/modules/03modlist.data.gz,
$CPAN/modules/02packages.details.txt.gz, and
$CPAN/authors/01mailrc.txt.gz. If a local CPAN mirror
isn't present, it will use the files fetched from a remote CPAN mirror
under CPAN by CPAN::Search::Lite::Index.
A CPAN::Search::Lite::Info object is created with
my $info = CPAN::Search::Lite::Info(CPAN => $cpan);
where $cpan specifies the top-level CPAN directory
underneath which the index files are found. Calling
$info->fetch_info();
will result in the object being populated with 3 hash references:
$info->{dists}This contains information on distributions. Keys of this hash reference are the distribution names, with the associated value being a hash reference with keys of
version - the version of the CPAN filefilename - the CPAN filenamedescription - a description, if availablesize - the size of the filedate - the last modified date (YYYY/MM/DD) of the filemd5 - the CPAN md5 checksum of the filemodules - specifies the modules present in the distribution: for my $module (keys %{$info->{$distname}->{modules}}) {
print "Module: $module\n";
}
chapterid - specifies the chapterid and the subchapter
for the distribution: for my $id (keys %{$info->{$distname}->{chapterid}}) {
print "For chapterid $id\n";
for my $sc (keys %{$info->{$distname}->{chapterid}->{$id}}) {
print " Subchapter: $sc\n";
}
}
requires - a hash reference whose keys are the names of
prerequisite modules required for the package and whose values are
the associated module versions. This information comes from the
META.yml file processed in CPAN::Search::Lite::Extract.$info->{mods}This contains information on modules. Keys of this hash reference are the module names, with the associated values being a hash reference with keys of
dist - the distribution name containing the moduleversion - the versiondescription - a description, if availablechapterid - the chapter id of the module, if presentdslip - a 5 character string specifying the dslip
(development, support, language, interface, public licence) information.$info->{auths}This contains information on CPAN authors. Keys of this hash reference are the CPAN ids, with the associated value being a hash reference with keys of
| CPAN-Search-Lite documentation | view source | Contained in the CPAN-Search-Lite distribution. |