-
-
30 Nov 2015 18:56:22 UTC
- Distribution: WebService-Audioscrobbler
- Module version: 0.08
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Issues (3)
- Testers (397 / 0 / 0)
- Kwalitee
Bus factor: 0- 41.06% Coverage
- License: unknown
- Activity
24 month- Tools
- Download (10.76KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
- Dependencies
- CLASS
- Cache::FileCache
- Carp
- Class::Accessor::Fast
- Class::Data::Accessor
- LWP::Simple
- NEXT
- Test::More
- UNIVERSAL::require
- URI
- URI::Escape
- XML::Simple
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
WebService::Audioscrobbler::Track - An object-oriented interface to the Audioscrobbler WebService API
SYNOPSIS
This module implements an object oriented abstraction of a track within the Audioscrobbler database.
use WebService::Audioscrobbler::Track; my $ws = WebService::Audioscrobbler->new; # get a track object for the track titled 'bar' by 'foo' my $track = $ws->track('foo', 'bar'); # retrieves the track's tags my @tags = $track->tags; # prints url for viewing aditional tag info print $track->url; # prints the tag's artist name print $track->artist->name;
This module inherits from WebService::Audioscrobbler::Base.
FIELDS
artist
The track's performing artist.
name
=head2title
The name (title) of a given track.
mbid
MusicBrainz ID as provided by the Audioscrobbler database.
url
URL for aditional info about the track.
METHODS
new($artist, $title, $data_fetcher)
new(\%fields)
Creates a new object using either the given
$artist
and$title
or the\%fields
hashref. The data fetcher object is a mandatory parameter and must be provided either as the second parameter or inside the\%fields
hashref.tags
Retrieves the track's top tags as available on Audioscrobbler's database.
Returns either a list of tags or a reference to an array of tags when called in list context or scalar context, respectively. The tags are returned as WebService::Audioscrobbler::Tag objects by default.
resource_path
Returns the URL from which other URLs used for fetching track info will be derived from.
AUTHOR
Nilson Santos Figueiredo Junior,
<nilsonsfj at cpan.org>
COPYRIGHT & LICENSE
Copyright 2006-2007 Nilson Santos Figueiredo Junior, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Module Install Instructions
To install WebService::Audioscrobbler, copy and paste the appropriate command in to your terminal.
cpanm WebService::Audioscrobbler
perl -MCPAN -e shell install WebService::Audioscrobbler
For more information on module installation, please visit the detailed CPAN module installation guide.