Kent Fredric > Gentoo-Perl-Distmap > Gentoo::Perl::Distmap::Record

Download:
Gentoo-Perl-Distmap-0.2.0.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Module Version: v0.2.0   Source  

NAME ^

Gentoo::Perl::Distmap::Record - A Single Distmap Record

VERSION ^

version 0.2.0

SYNOPSIS ^

    record: {
        category:
        package:
        repository:
        versions_gentoo: [

        ]
    }

    my $record = Gentoo::Perl::Distmap::Record->new(
        category => 'dev-perl',
        package  => 'Moo',
        repository => 'perl-experimental',
    );

    $record->description # dev-perl/Moo::perl-experimental

    $record->has_versions() # undef

    $record->describe_version( '1.1') #     '=dev-perl/Moo-1.1::perl-experimental'

    $record->add_version('1.1');

    my ( @packages ) = $record->enumerate_packages();

    @packages = (
        '=dev-perl/Moo-1.1::perl-experimental'
    )

ATTRIBUTES ^

category

package

repository

versions_gentoo

METHODS ^

description

A pretty description of this object

    say $object->description
    # dev-perl/Foo::gentoo

describe_version

Like "description" but for a specified version

    say $object->describe_version('1.1');
    # =dev-perl/Foo-1.1::gentoo

enumerate_packages

Returns package declarations for all versions

        my @packages = $instance->enumerate_packages();

    # =dev-perl/Foo-1.1::gentoo
    # =dev-perl/Foo-1.2::gentoo

to_rec

        my $datastructure = $instance->to_rec

CLASS METHODS ^

from_rec

        my $instance = G:P:D:Record->from_rec( $datastructure );

ATTRIBUTE METHODS ^

category -> category

package -> package

repository -> repository

versions_gentoo -> versions_gentoo

add_version -> versions_gentoo.push

        $instance->add_version('1.1');

has_versions -> versions_gentoo.count

        if( $instance->has_versions ){

        }

AUTHOR ^

Kent Fredric <kentfredric@gmail.com>

COPYRIGHT AND LICENSE ^

This software is copyright (c) 2013 by Kent Fredric <kentfredric@gmail.com>.

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

syntax highlighting: