| 1 | package WebService::LastFM::Playlist; | ||||||||||
| 2 | |||||||||||
| 3 | 2 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 2 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | |||||||||||
| 6 | 2 | ▶ | use base qw(Class::Accessor); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 7 | 2 | our $VERSION = '0.07'; | |||||||||
| 8 | |||||||||||
| 9 | 2 | __PACKAGE__->mk_accessors( | |||||||||
| 10 | qw( tracks ) | ||||||||||
| 11 | ); | ||||||||||
| 12 | |||||||||||
| 13 | 0 | ▶ | sub new { | ||||||||
|
Subroutine
new: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||
| 14 | 0 | my ( $class, $args ) = @_; | |||||||||
| 15 | 0 | bless $args, $class; | |||||||||
| 16 | } | ||||||||||
| 17 | |||||||||||
| 18 | 0 | ▶ | sub get_next_track { | ||||||||
|
Subroutine
get_next_track: not called CC=2 SCAR=17.9
Pod
documented
| |||||||||||
| 19 | 0 | my $self = shift; | |||||||||
| 20 | 0 | ▶ | return $self->tracks_left() ? pop @{ $self->{tracks} } : undef; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 21 | } | ||||||||||
| 22 | |||||||||||
| 23 | 0 | ▶ | sub tracks_left { | ||||||||
|
Subroutine
tracks_left: not called CC=2 SCAR=17.9
Pod
documented
| |||||||||||
| 24 | 0 | my $self = shift; | |||||||||
| 25 | 0 | ▶ | return defined $self->{tracks} ? scalar( @{ $self->{tracks} } ) : 0; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 26 | } | ||||||||||
| 27 | |||||||||||
| 28 | 2 | 1; | |||||||||
| 29 | __END__ | ||||||||||