MetaIOTagLib Class Reference

#include <metaiotaglib.h>

Inheritance diagram for MetaIOTagLib:

MetaIO

List of all members.


Detailed Description

Definition at line 22 of file metaiotaglib.h.


Public Member Functions

 MetaIOTagLib (void)
virtual ~MetaIOTagLib (void)
bool write (Metadata *mdata, bool exclusive=false)
 Writes metadata back to a file.
Metadataread (QString filename)
 Reads Metadata from a file.

Static Public Member Functions

static QImage getAlbumArt (QString filename, ImageType type)
 Read the albumart image from the file.

Private Member Functions

int getTrackLength (QString filename)
 Find the length of the track (in seconds).
AlbumArtList readAlbumArt (TagLib::ID3v2::Tag *tag)
 Read the albumart image from the file.
UserTextIdentificationFrame * find (TagLib::ID3v2::Tag *tag, const String &description)
 Find the a custom comment tag by description. This is a copy of the same function in the TagLib::ID3v2::UserTextIdentificationFrame Class with a static instead of dynamic cast.

Constructor & Destructor Documentation

MetaIOTagLib::MetaIOTagLib ( void   ) 

Definition at line 8 of file metaiotaglib.cpp.

MetaIOTagLib::~MetaIOTagLib ( void   )  [virtual]

Definition at line 13 of file metaiotaglib.cpp.


Member Function Documentation

bool MetaIOTagLib::write ( Metadata mdata,
bool  exclusive = false 
) [virtual]

Writes metadata back to a file.

Parameters:
mdata A pointer to a Metadata object
exclusive Flag to indicate if only the data in mdata should be in the file. If false, any unrecognised tags already in the file will be maintained.
Returns:
Boolean to indicate success/failure.

Implements MetaIO.

Definition at line 26 of file metaiotaglib.cpp.

Metadata * MetaIOTagLib::read ( QString  filename  )  [virtual]

Reads Metadata from a file.

Parameters:
filename The filename to read metadata from.
Returns:
Metadata pointer or NULL on error

Implements MetaIO.

Definition at line 123 of file metaiotaglib.cpp.

QImage MetaIOTagLib::getAlbumArt ( QString  filename,
ImageType  type 
) [static]

Read the albumart image from the file.

Parameters:
filename The filename for which we want to find the length.
type The type of image we want - front/back etc
Returns:
A QByteArray that can contains the image data.

Definition at line 252 of file metaiotaglib.cpp.

Referenced by Metadata::getAlbumArt().

int MetaIOTagLib::getTrackLength ( QString  filename  )  [private, virtual]

Find the length of the track (in seconds).

Parameters:
filename The filename for which we want to find the length.
Returns:
An integer (signed!) to represent the length in seconds.

Implements MetaIO.

Definition at line 231 of file metaiotaglib.cpp.

AlbumArtList MetaIOTagLib::readAlbumArt ( TagLib::ID3v2::Tag *  tag  )  [private]

Read the albumart image from the file.

Parameters:
tag The ID3v2 tag object in which to look for Album Art
Returns:
A QValueList containing a list of AlbumArtImage structs with the type and description of the APIC tag.

Definition at line 318 of file metaiotaglib.cpp.

Referenced by read().

UserTextIdentificationFrame * MetaIOTagLib::find ( TagLib::ID3v2::Tag *  tag,
const String &  description 
) [private]

Find the a custom comment tag by description. This is a copy of the same function in the TagLib::ID3v2::UserTextIdentificationFrame Class with a static instead of dynamic cast.

Parameters:
tag Pointer to TagLib::ID3v2::Tag object
description Description of tag to search for
Returns:
Pointer to frame

Definition at line 395 of file metaiotaglib.cpp.

Referenced by read(), and write().


The documentation for this class was generated from the following files:

Generated on Sat Dec 18 05:16:05 2010 for MythTV by  doxygen 1.5.5