Added the methods to check which kind of tags the file actually has.

This commit is contained in:
Tsuda Kageyu
2013-07-04 18:11:33 +09:00
parent 7e866e11ad
commit 1503909824
17 changed files with 164 additions and 8 deletions

View File

@ -47,7 +47,7 @@ using namespace TagLib;
namespace
{
enum { ApeAPEIndex, ApeID3v1Index };
enum { ApeAPEIndex = 0, ApeID3v1Index = 1 };
}
class APE::File::FilePrivate
@ -235,6 +235,16 @@ void APE::File::strip(int tags)
}
}
bool APE::File::hasAPETag() const
{
return d->hasAPE;
}
bool APE::File::hasID3v1Tag() const
{
return d->hasID3v1;
}
////////////////////////////////////////////////////////////////////////////////
// private members
////////////////////////////////////////////////////////////////////////////////

View File

@ -186,6 +186,16 @@ namespace TagLib {
*/
void strip(int tags = AllTags);
/*!
* Returns whether or not the file on disk contains an APE tag.
*/
bool hasAPETag() const;
/*!
* Returns whether or not the file on disk contains an ID3v1 tag.
*/
bool hasID3v1Tag() const;
private:
File(const File &);
File &operator=(const File &);