1 package BackPAN::Index::Release;
7 q[""] => sub { $_[0]->distvname },
10 use BackPAN::Index::Role::AsHash;
13 return qw(dist version cpanid date path maturity);
18 return $self->path->filename;
21 # Compatibility with PBP
33 BackPAN::Index::Release - A single release of a distribution
37 my $b = BackPAN::Index->new();
39 # Find version 1.2.3 of Acme-Colour
40 my $release = $b->release("Acme-Colour", '1.2.3');
42 print " CPANID: " . $release->cpanid . "\n";
43 print " Date: " . $release->date . "\n";
44 print " Dist: " . $release->dist . "\n";
45 print "Distvname: " . $release->distvname . "\n";
46 print " Filename: " . $release->filename . "\n";
47 print " Maturity: " . $release->maturity . "\n";
48 print " Path: " . $release->path . "\n";
49 print " Version: " . $release->version . "\n";
53 BackPAN::Index::Release objects represent releases,
54 individual tarballs/zip files, of a distribution on BackPAN.
56 For example, Acme-Pony-1.2.3.tar.gz is a release of the Acme-Pony
63 my $cpanid = $release->cpanid;
65 Returns the PAUSE ID of the author of the release.
69 my $date = $release->date;
71 Returns the date of the release, in UNIX epoch seconds.
75 my $dist_name = $release->dist;
77 Returns the name of the distribution this release belongs to.
81 my $distvname = $release->distvname;
83 Returns the name of the distribution, hyphen, and version.
87 my $filename = $release->filename;
89 Returns the filename of the release, just the file part.
93 my $maturity = $release->maturity;
95 Returns the maturity of the release.
99 my $path = $release->path;
101 Returns the full path on CPAN to the release. This is a
102 L<BackPAN::File> object.
106 my $version = $release->version;
108 Returns the version of the release:
112 my $data = $release->as_hash;
114 Returns a hash ref containing the data inside C<$release>.
119 Leon Brocard <acme@astray.com> and Michael G Schwern <schwern@pobox.com>
123 Copyright (C) 2005-2009, Leon Brocard
125 This module is free software; you can redistribute it or modify it under
126 the same terms as Perl itself.
130 L<BackPAN::Index>, L<BackPAN::Index::Dist>, L<BackPAN::Index::File>