Net_CDDB
[ class tree: Net_CDDB ] [ index: Net_CDDB ] [ all elements ]

Class: Net_CDDB_DiscId

Source Location: /Net_CDDB-0.1.0/CDDB/DiscId.php

Class Overview


Static class providing helper functions to calculate disc ids


Methods


Inherited Variables

Inherited Methods


Class Details

[line 22]
Static class providing helper functions to calculate disc ids

Although CDDB servers provide a method to calculate disc ids via sending a query to the server and receiving the disc id in return, sometimes it's nice to be not have to query the server to get this information. Given the track offsets and disc length this static class can calculate the disc id.



[ Top ]


Method Detail

calculateDiscId   [line 36]

string calculateDiscId( array $track_offsets, int $disc_length)

Calculate the disc id from the track offsets and disc length

Parameters:

array   $track_offsets   — 
int   $disc_length   —  Disc length in seconds

[ Top ]

sum   [line 58]

int sum( int $n)

Helper function for calculateDiscId() method, sum digits in track offset

Parameters:

int   $n   — 

[ Top ]


Documentation generated on Mon, 11 Mar 2019 14:39:30 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.