Properties

$file

$file : \duncan3dc\MetaAudio\Interfaces\FileInterface

Type

\duncan3dc\MetaAudio\Interfaces\FileInterface — The file handler.

Methods

addDefaultModules()

addDefaultModules() : $this

Add the default set of modules the library ships with.

Returns

$this

clearModules()

clearModules() : $this

Remove all previously defined modules.

Returns

$this

__construct()

__construct(\duncan3dc\MetaAudio\Interfaces\FileInterface  $file) 

Create a new instance from a local file.

Parameters

\duncan3dc\MetaAudio\Interfaces\FileInterface $file

The file to work with

getTitle()

getTitle() : string

Get the track title.

Returns

string

getTrackNumber()

getTrackNumber() : integer

Get the track number.

Returns

integer

getArtist()

getArtist() : string

Get the artist name.

Returns

string

getAlbum()

getAlbum() : string

Get the album name.

Returns

string

getYear()

getYear() : integer

Get the release year.

Returns

integer

setTitle()

setTitle(string  $title) : $this

Set the track title.

Parameters

string $title

The title name

Returns

$this

setTrackNumber()

setTrackNumber(integer  $track) : $this

Set the track number.

Parameters

integer $track

The track number

Returns

$this

setArtist()

setArtist(string  $artist) : $this

Set the artist name.

Parameters

string $artist

The artist name

Returns

$this

setAlbum()

setAlbum(string  $album) : $this

Set the album name.

Parameters

string $album

The album name

Returns

$this

setYear()

setYear(integer  $year) : $this

Set the release year.

Parameters

integer $year

The release year

Returns

$this

save()

save() : $this

Save the changes currently pending.

Returns

$this

getModuleString()

getModuleString(string  $method) : string

Get a string from the active modules.

Modules should be loaded in priority sequence as this method returns the first match.

Parameters

string $method

The method name to call on the modules

Returns

string

getModuleInt()

getModuleInt(string  $method) : integer

Get an integer from the active modules.

Modules should be loaded in priority sequence as this method returns the first match.

Parameters

string $method

The method name to call on the modules

Returns

integer

setModuleValue()

setModuleValue(string  $method, mixed  $value) : $this

Set a value using all active modules.

Parameters

string $method

The method name to call on the modules

mixed $value

The value to pass to the module method

Returns

$this