Qmmp
Public Member Functions
PlayListTrack Class Reference

#include <playlisttrack.h>

Inheritance diagram for PlayListTrack:
PlayListItem

List of all members.

Public Member Functions

 PlayListTrack ()
 PlayListTrack (const PlayListTrack &item)
 PlayListTrack (FileInfo *info)
virtual ~PlayListTrack ()
const QString formattedTitle (int column)
const QStringList formattedTitles ()
const QString formattedLength ()
qint64 length () const
void setLength (qint64 length)
const QString url () const
void updateMetaData (const QMap< Qmmp::MetaData, QString > &metaData)
void updateMetaData ()
const QString groupName ()
bool isGroup () const
void setTrackIndex (int track_index)
int trackIndex () const
void beginUsage ()
void endUsage ()
void deleteLater ()
bool isSheduledForDeletion () const
bool isUsed () const

Detailed Description

The PlayListTrack class provides a track for use with the PlayListModel class.

Author:
Ilya Kotov <forkotov02@hotmail.ru>

Constructor & Destructor Documentation

Constructs an empty plalist item.

PlayListTrack ( const PlayListTrack item)

Constructs a new PlayListTrack that is a copy of the given item

PlayListTrack ( FileInfo info)

Constructs plalist item with given metadata.

Parameters:
infoMedia file information.
virtual ~PlayListTrack ( ) [virtual]

Object destructor.


Member Function Documentation

void beginUsage ( )

Prepares for usage. Increases reference counter.

void deleteLater ( )

Shedules track object for deletion.

void endUsage ( )

End of usage. Decreases reference counter.

const QString formattedLength ( ) [virtual]

Returns formatted length of the item.

Implements PlayListItem.

const QString formattedTitle ( int  column) [virtual]

Returns formatted title of the item.

Parameters:
columnNumber of column.

Implements PlayListItem.

const QStringList formattedTitles ( ) [virtual]

Returns the list of the formatted titles for all columns.

Implements PlayListItem.

const QString groupName ( )

Returns name of the parent group.

bool isGroup ( ) const [virtual]

Returns false.

Implements PlayListItem.

bool isSheduledForDeletion ( ) const

Returns true if the track object is sheduled for deletion.

bool isUsed ( ) const

Indicates that instance is currently busy in some kind of operation (tags editing etc.) and can't be deleted at the moment. Call deleteLater() instead of delete operator call.

qint64 length ( ) const

Returns song length in seconds.

void setLength ( qint64  length)

Sets length in seconds.

void setTrackIndex ( int  track_index) [virtual]

Sets the index of the track.

Reimplemented from PlayListItem.

int trackIndex ( ) const [virtual]

Returns the index of the track. Default implementation returns -1.

Reimplemented from PlayListItem.

void updateMetaData ( const QMap< Qmmp::MetaData, QString > &  metaData)

Updates current metadata.

Parameters:
metaDataMap with metadata values.
void updateMetaData ( )

Gets new metadata from file (works for local files only).

const QString url ( ) const

Same as url()


The documentation for this class was generated from the following file:
 All Classes Functions Variables Enumerations Enumerator