Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef TAGLIB_APETAG_H
00027 #define TAGLIB_APETAG_H
00028
00029 #include "tag.h"
00030 #include "tbytevector.h"
00031 #include "tmap.h"
00032 #include "tstring.h"
00033 #include "taglib_export.h"
00034
00035 #include "apeitem.h"
00036
00037 namespace TagLib {
00038
00039 class File;
00040
00042
00043 namespace APE {
00044
00045 class Footer;
00046
00052 typedef Map<const String, Item> ItemListMap;
00053
00054
00056
00057 class TAGLIB_EXPORT Tag : public TagLib::Tag
00058 {
00059 public:
00063 Tag();
00064
00069 Tag(TagLib::File *file, long footerLocation);
00070
00074 virtual ~Tag();
00075
00080 ByteVector render() const;
00081
00086 static ByteVector fileIdentifier();
00087
00088
00089
00090 virtual String title() const;
00091 virtual String artist() const;
00092 virtual String album() const;
00093 virtual String comment() const;
00094 virtual String genre() const;
00095 virtual uint year() const;
00096 virtual uint track() const;
00097
00098 virtual void setTitle(const String &s);
00099 virtual void setArtist(const String &s);
00100 virtual void setAlbum(const String &s);
00101 virtual void setComment(const String &s);
00102 virtual void setGenre(const String &s);
00103 virtual void setYear(uint i);
00104 virtual void setTrack(uint i);
00105
00120 PropertyMap properties() const;
00121
00122 void removeUnsupportedProperties(const StringList &properties);
00123
00130 PropertyMap setProperties(const PropertyMap &);
00131
00135 static bool checkKey(const String&);
00136
00140 Footer *footer() const;
00141
00154 const ItemListMap &itemListMap() const;
00155
00159 void removeItem(const String &key);
00160
00166 void addValue(const String &key, const String &value, bool replace = true);
00167
00173 void setData(const String &key, const ByteVector &value);
00174
00179 void setItem(const String &key, const Item &item);
00180
00184 bool isEmpty() const;
00185
00186 protected:
00187
00191 void read();
00192
00196 void parse(const ByteVector &data);
00197
00198 private:
00199 Tag(const Tag &);
00200 Tag &operator=(const Tag &);
00201
00202 class TagPrivate;
00203 TagPrivate *d;
00204 };
00205 }
00206 }
00207
00208 #endif