GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  MUSICBRAINZ::DISCID (3)

.ds Aq ’

NAME

MusicBrainz::DiscID - Perl interface for the MusicBrainz libdiscid library

CONTENTS

SYNOPSIS



  use MusicBrainz::DiscID;

  my $discid = MusicBrainz::DiscID->new();
  if ( $disc->read() == 0 ) {
      print STDERR "Error: " . $discid->error_msg() . "\n";
      exit(1);
  }
  print "DiscID: " . $discid->id() . "\n";



DESCRIPTION

MusicBrainz::DiscID is a class to calculate a MusicBrainz DiscID from an audio CD in the drive. The coding style is slightly different to the C interface to libdiscid, because it makes use of perl’s Object Oriented functionality.
MusicBrainz::DiscID::default_device() Returns a device string for the default device for this platform.
MusicBrainz::DiscID::new( [$device] ) Construct a new DiscID object.

As an optional argument the name of the device to read the ID from may be given. If you donO\k:^t specify a device here you can later read the ID with the read method.

$discid->error_msg() Return a human-readable error message of the last error that occured.
$discid->first_track_num() Return the number of the first track on this disc (usually 1). Returns undef if no ID was yet read.
$discid->last_track_num() Return the number of the last track on this disc.
$discid->id() Returns the DiscID as a string. Returns undef if no ID was yet read.
$discid->last_track_num() Return the number of the last track on this disc. Returns undef if no ID was yet read.
$discid->put( $first_track, $sectors, $offset1, $offset2, ... ) This function may be used if the TOC has been read earlier and you want to calculate the disc ID afterwards, without accessing the disc drive.
$discid->read( [$device] ) Read the disc ID from the given device. If no device is given the default device of the platform will be used. On error, this function returns false and sets the error message which you can access $discid->error_msg().
$discid->sectors() Return the length of the disc in sectors. Returns undef if no ID was yet read.
$discid->submission_url() Returns a submission URL for the DiscID as a string. Returns undef if no ID was yet read.
$discid->track_length( $track_num ) Return the length of a track in sectors.
$discid->track_offset( $track_num ) Return the sector offset of a track.
$discid->webservice_url() Returns a Webservice URL for the DiscID as a string. Returns undef if no ID was yet read.

SEE ALSO

<http://musicbrainz.org/doc/libdiscid>

AUTHOR

Nicholas J. Humfrey <njh@aelius.com>

COPYRIGHT AND LICENSE

Copyright (C) 2009 Nicholas J. Humfrey

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

POD ERRORS

Hey! <B>The above document had some coding errors, which are explained below:B>
Around line 159: Non-ASCII character seen before =encoding in ’donO\k:^t’. Assuming ISO8859-1
Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 MUSICBRAINZ::DISCID (3) 2016-03-17

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.