Home | Trees | Indices | Help |
---|
|
object --+ | Disc
Represents an Audio CD.
This class represents an Audio CD. A disc can have an ID (the MusicBrainz DiscID), which is calculated from the CD's table of contents (TOC). There may also be data from the TOC like the length of the disc in sectors, as well as position and length of the tracks.
Note that different TOCs, maybe due to different pressings, lead to
different DiscIDs. Conversely, if two different discs have the same TOC,
they also have the same DiscID (which is unlikely but not impossible).
DiscIDs are always 28 characters long and look like this:
'J68I_CDcUFdCRCIbHSEbTBCbooA-'
. Sometimes they are also
referred to as CDIndex IDs.
The MusicBrainz web service only returns the DiscID and the number of sectors. The DiscID calculation function musicbrainz2.disc.readDisc, however, can retrieve the other attributes of Disc from an Audio CD in the disc drive.
Instance Methods | |||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from |
Properties | |
id The MusicBrainz DiscID. |
|
sectors The length of the disc in sectors. |
|
firstTrackNum The number of the first track on this disc. |
|
lastTrackNum The number of the last track on this disc. |
|
tracks Sector offset and length of all tracks. |
|
Inherited from |
Method Details |
Constructor.
|
Returns the MusicBrainz DiscID.
|
Sets the MusicBrainz DiscId.
|
Returns the length of the disc in sectors.
|
Sets the length of the disc in sectors.
|
Returns the number of the first track on this disc.
|
Sets the number of the first track on this disc.
|
Returns the number of the last track on this disc.
|
Sets the number of the last track on this disc.
|
Returns the sector offset and length of this disc. This method returns a list of tuples containing the track offset and length in sectors for all tracks on this disc. The track offset is measured from the beginning of the disc, the length is relative to the track's offset. Note that the leadout track is not included.
|
Adds a track to the list. This method adds an (offset, length) tuple to the list of tracks. The leadout track must not be added. The total length of the disc can be set using setSectors.
See Also: getTracks |
Property Details |
idThe MusicBrainz DiscID. |
sectorsThe length of the disc in sectors.
|
firstTrackNumThe number of the first track on this disc.
|
lastTrackNumThe number of the last track on this disc.
|
tracksSector offset and length of all tracks.
|
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Sat Nov 19 22:07:31 2011 | http://epydoc.sourceforge.net |