MP3::Napster::Channel - Object-oriented access to Napster channels
@channels = $nap->channels; foreach $chan (@channels) { print $chan->name,"\n"; print $chan->topic,"\n"; print $chan->user_count,"\n"; print $chan->server,"\n"; @users = $chan->users,"\n"; } $chan->join && print "Welcome to $chan!\n"; $chan->part && print "Goodbye!\n";
MP3::Napster::Channel provides object-oriented access to discussion channels on the Napster service.
Channel objects are normally not constructed from scratch but are returned by the MPEG::Napster channels() method.
Methods provide access to various attributes of the Channel object and allow you to join and depart the channel.
The accessors provide read-only access to the following Channel attributes.
Accessor Description -------- ----------- $channel->name Channel name $channel->user_count Number of users enrolled in channel $channel->topic Channel's topic (welcome banner) $channel->server MP3::Napster object from which channel was derived
This method returns the current list of users subscribed to the channel. The return value is an array of MP3::Napster::User objects.
Attempt to join the channel, and return a true result if successful.
Attempt to join the channel, returning a true result if successful.
Attempt to depart from the channel, returning a true result if successful.
If used in a string context, MPEG::Napster::Channel objects will invoke the name() method, allowing the objects to be directly interpolated into strings, printed, and pattern matched.
Lincoln Stein <lstein@cshl.org>.
Copyright (c) 2000 Cold Spring Harbor Laboratory. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
MP3::Napster, MP3::Napster::Song, MP3::Napster::User, and MPEG::Napster::Transfer
To install MP3::Napster, copy and paste the appropriate command in to your terminal.
cpanm
cpanm MP3::Napster
CPAN shell
perl -MCPAN -e shell install MP3::Napster
For more information on module installation, please visit the detailed CPAN module installation guide.