The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

slackget10::PackageList - This class is a container of slackget10::Package object

VERSION

Version 1.0.0

SYNOPSIS

This class is a container of slackget10::Package object, and allow you to perform some operations on this packages list. As the Package class, it is a slack-get's internal representation of data.

    use slackget10::PackageList;

    my $packagelist = slackget10::PackageList->new();
    $packagelist->add($package);
    $packagelist->get($index);
    my $package = $packagelist->Shift();
    

CONSTRUCTOR

This class constructor don't take any parameters, but you can eventually disable the root tag <packagelist> by using 'no-root-tag' => 1.

        my $PackageList = new slackget10::PackageList ();
        my $PackageList = new slackget10::PackageList ('no-root-tag' => 1);

FUNCTIONS

add

Add the package passed in argument to the list. The argument must be a slackget10::Package object

        $PackageList->add($package);

get

return the $index slackget10::Package object in the list

        $PackageList->get($index);

get_all

return a reference on an array containing all packages.

        $arrayref = $PackageList->get_all();

Shift

Same as the Perl shift. Shifts of and return the first slackget10::Package of the slackget10::PackageList;

        $package = $PackageList->Shift();

to_XML

return an XML encoded string.

        $xml = $PackageList->to_XML();

to_string

Alias for to_XML()

AUTHOR

DUPUIS Arnaud, <a.dupuis@infinityperl.org>

BUGS

Please report any bugs or feature requests to bug-slackget10-PackageList@rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=slackget10. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

ACKNOWLEDGEMENTS

COPYRIGHT & LICENSE

Copyright 2005 DUPUIS Arnaud, All Rights Reserved.

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