#include <field_impl.h>
Inheritance diagram for ID3_FieldImpl:
Public Member Functions | |
~ID3_FieldImpl () | |
void | Clear () |
Clears any data and frees any memory associated with the field. | |
size_t | Size () const |
Returns the size of a field. | |
size_t | BinSize () const |
size_t | GetNumTextItems () const |
Returns the number of items in a text list. | |
ID3_Field & | operator= (uint32 val) |
A shortcut for the Set method. | |
void | Set (uint32) |
Sets the value of the field to the specified integer. | |
uint32 | Get () const |
Returns the value of the integer field. | |
void | SetInteger (uint32) |
uint32 | GetInteger () const |
ID3_Field & | operator= (const char *s) |
Shortcut for the Set operator. | |
size_t | Set (const char *data) |
Copies the supplied string to the field. You may dispose of the source string after a call to this method. . | |
size_t | Get (char *, size_t) const |
Copies the contents of the field into the supplied buffer, up to the number of characters specified; for fields with multiple entries, the optional third parameter indicates which of the fields to retrieve. | |
size_t | Get (char *, size_t, size_t) const |
const char * | GetRawText () const |
const char * | GetRawTextItem (size_t) const |
size_t | Add (const char *data) |
dami::String | GetText () const |
dami::String | GetTextItem (size_t) const |
size_t | SetText (dami::String) |
size_t | AddText (dami::String) |
ID3_Field & | operator= (const unicode_t *s) |
Shortcut for the Set operator. Performs similarly as operator=(const char*), taking a unicode_t string as a parameter rather than an ascii string. | |
size_t | Set (const unicode_t *) |
Copies the supplied unicode string to the field. | |
size_t | Get (unicode_t *buffer, size_t) const |
Copies the contents of the field into the supplied buffer, up to the number of characters specified; for fields with multiple entries, the optional third parameter indicates which of the fields to retrieve. | |
size_t | Get (unicode_t *buffer, size_t, size_t) const |
size_t | Add (const unicode_t *) |
const unicode_t * | GetRawUnicodeText () const |
const unicode_t * | GetRawUnicodeTextItem (size_t) const |
size_t | Set (const uchar *buf, size_t size) |
size_t | Set (const char *buf, size_t size) |
size_t | Get (uchar *, size_t) const |
Copies the field's internal string to the buffer. | |
const uchar * | GetRawBinary () const |
void | FromFile (const char *) |
Copies binary data from the file specified to the field. | |
void | ToFile (const char *sInfo) const |
Copies binary data from the field to the specified file. | |
size_t | SetBinary (dami::BString) |
Copies the supplied unicode string to the field. | |
dami::BString | GetBinary () const |
ID3_Field & | operator= (const ID3_Field &) |
bool | InScope (ID3_V2Spec spec) const |
ID3_FieldID | GetID () const |
ID3_FieldType | GetType () const |
bool | SetEncoding (ID3_TextEnc enc) |
ID3_TextEnc | GetEncoding () const |
bool | IsEncodable () const |
void | Render (ID3_Writer &) const |
bool | Parse (ID3_Reader &) |
bool | HasChanged () const |
Protected Member Functions | |
void | RenderInteger (ID3_Writer &) const |
void | RenderText (ID3_Writer &) const |
void | RenderBinary (ID3_Writer &) const |
bool | ParseInteger (ID3_Reader &) |
bool | ParseText (ID3_Reader &) |
bool | ParseBinary (ID3_Reader &) |
|
|
|
Implements ID3_Field. Definition at line 61 of file field_string_unicode.cpp. References Add(), GetEncoding(), GetType(), ID3FTY_TEXTSTRING, and ID3TE_UNICODE. |
|
Implements ID3_Field. Definition at line 250 of file field_string_ascii.cpp. References Add(), GetType(), and ID3FTY_TEXTSTRING. Referenced by Add(). |
|
Definition at line 240 of file field_string_ascii.cpp. References AddText(), GetType(), and ID3FTY_TEXTSTRING. Referenced by AddText(), and ParseText(). |
|
Implements ID3_Field. Definition at line 992 of file field.cpp. References GetEncoding(), ID3_TextEnc, ID3FF_CSTR, ID3FTY_TEXTSTRING, ID3TE_UNICODE, and Size(). |
|
Clears any data and frees any memory associated with the field.
Implements ID3_Field. Definition at line 923 of file field.cpp. References GetEncoding(), ID3FTY_BINARY, ID3FTY_INTEGER, ID3FTY_TEXTSTRING, ID3TE_ASCII, and ID3TE_UNICODE. Referenced by ParseInteger(), ParseText(), SetBinary(), and SetInteger(). |
|
Copies binary data from the file specified to the field.
Implements ID3_Field. Definition at line 136 of file field_binary.cpp. References FromFile(), GetType(), ID3FTY_BINARY, NULL, Set(), and uchar. Referenced by FromFile(). |
|
Copies the field's internal string to the buffer. It copies the data in the field into the buffer, for as many bytes as the field contains, or the size of buffer, whichever is smaller.
Implements ID3_Field. Definition at line 113 of file field_binary.cpp. References GetType(), ID3FTY_BINARY, min, and NULL. |
|
Implements ID3_Field. Definition at line 139 of file field_string_unicode.cpp. References GetEncoding(), GetNumTextItems(), GetRawUnicodeTextItem(), GetType(), ID3FTY_TEXTSTRING, ID3TE_UNICODE, min, NULL, NULL_UNICODE, and unicode_t. |
|
Copies the contents of the field into the supplied buffer, up to the number of characters specified; for fields with multiple entries, the optional third parameter indicates which of the fields to retrieve. Performs similarly as the ASCII Get(char *, size_t, size_t) method, taking a unicode_t string as a parameter rather than an ascii string. The maxChars parameter still represents the maximum number of characters, not bytes.
Implements ID3_Field. Definition at line 93 of file field_string_unicode.cpp. References GetEncoding(), GetType(), ID3FTY_TEXTSTRING, ID3TE_UNICODE, min, NULL, NULL_UNICODE, and Size(). |
|
Implements ID3_Field. Definition at line 106 of file field_string_ascii.cpp. References GetEncoding(), GetTextItem(), GetType(), ID3FTY_TEXTSTRING, ID3TE_ASCII, min, and NULL. |
|
Copies the contents of the field into the supplied buffer, up to the number of characters specified; for fields with multiple entries, the optional third parameter indicates which of the fields to retrieve. The third parameter is useful when using text lists (see Add(const char*) for more details). The default value for this third parameter is 1, which returns the entire string if the field contains only one item. It returns the number of characters (not bytes necessarily, and not including any NULL terminator) of the supplied buffer that are now used.
It fills the buffer with as much data from the field as is present in the field, or as large as the buffer, whichever is smaller.
This fills the buffer with up to the first 1024 characters from the third element of the text list.
Implements ID3_Field. Definition at line 87 of file field_string_ascii.cpp. References GetEncoding(), GetText(), GetType(), ID3FTY_TEXTSTRING, ID3TE_ASCII, min, and NULL. |
|
Returns the value of the integer field.
Implements ID3_Field. Definition at line 72 of file field_integer.cpp. References GetInteger(). |
|
Definition at line 81 of file field_binary.cpp. References GetType(), and ID3FTY_BINARY. Referenced by operator=(). |
|
Implements ID3_Field. Definition at line 105 of file field_impl.h. References ID3_TextEnc. Referenced by Add(), BinSize(), Clear(), Get(), GetRawText(), GetRawTextItem(), GetRawUnicodeText(), GetRawUnicodeTextItem(), GetTextItem(), operator=(), ParseText(), RenderText(), Set(), and SetEncoding(). |
|
Implements ID3_Field. Definition at line 102 of file field_impl.h. References ID3_FieldID. |
|
Definition at line 77 of file field_integer.cpp. References GetType(), and ID3FTY_INTEGER. Referenced by Get(), and operator=(). |
|
Returns the number of items in a text list.
Implements ID3_Field. Definition at line 399 of file field_string_ascii.cpp. Referenced by Get(), GetRawTextItem(), and GetRawUnicodeTextItem(). |
|
Implements ID3_Field. Definition at line 92 of file field_binary.cpp. References GetType(), ID3FTY_BINARY, NULL, and uchar. |
|
Implements ID3_Field. Definition at line 261 of file field_string_ascii.cpp. References GetEncoding(), GetType(), ID3FTY_TEXTSTRING, ID3TE_ASCII, and NULL. |
|
Implements ID3_Field. Definition at line 272 of file field_string_ascii.cpp. References GetEncoding(), GetNumTextItems(), GetRawTextItem(), GetType(), ID3FTY_TEXTSTRING, ID3TE_ASCII, and NULL. Referenced by GetRawTextItem(), and GetTextItem(). |
|
Implements ID3_Field. Definition at line 111 of file field_string_unicode.cpp. References GetEncoding(), GetType(), ID3FTY_TEXTSTRING, ID3TE_UNICODE, NULL, and unicode_t. |
|
Implements ID3_Field. Definition at line 122 of file field_string_unicode.cpp. References GetEncoding(), GetNumTextItems(), GetRawUnicodeTextItem(), GetType(), ID3FTY_TEXTSTRING, ID3TE_UNICODE, NULL, and unicode_t. Referenced by Get(), and GetRawUnicodeTextItem(). |
|
Definition at line 124 of file field_string_ascii.cpp. References GetType(), and ID3FTY_TEXTSTRING. Referenced by Get(), and operator=(). |
|
Definition at line 134 of file field_string_ascii.cpp. References GetEncoding(), GetRawTextItem(), GetTextItem(), GetType(), ID3FTY_TEXTSTRING, ID3TE_ASCII, and NULL. Referenced by Get(), and GetTextItem(). |
|
Implements ID3_Field. Definition at line 103 of file field_impl.h. References ID3_FieldType. Referenced by Add(), AddText(), FromFile(), Get(), GetBinary(), GetInteger(), GetRawBinary(), GetRawText(), GetRawTextItem(), GetRawUnicodeText(), GetRawUnicodeTextItem(), GetText(), GetTextItem(), operator=(), Parse(), Render(), Set(), SetBinary(), SetInteger(), SetText(), and ToFile(). |
|
Implements ID3_Field. |
|
Implements ID3_Field. Definition at line 99 of file field_impl.h. |
|
Implements ID3_Field. Definition at line 106 of file field_impl.h. References ID3FF_ENCODABLE. Referenced by SetEncoding(). |
|
Implements ID3_Field. Definition at line 1143 of file field.cpp. References GetBinary(), GetEncoding(), GetInteger(), GetText(), GetType(), ID3FTY_BINARY, ID3FTY_INTEGER, ID3FTY_TEXTSTRING, operator=(), SetBinary(), SetEncoding(), SetInteger(), and SetText(). |
|
Shortcut for the Set operator. Performs similarly as operator=(const char*), taking a unicode_t string as a parameter rather than an ascii string.
Implements ID3_Field. Definition at line 75 of file field_impl.h. References unicode_t. |
|
Shortcut for the Set operator.
Implements ID3_Field. Definition at line 61 of file field_impl.h. |
|
A shortcut for the Set method.
Implements ID3_Field. Definition at line 53 of file field_impl.h. References Set(). Referenced by operator=(). |
|
Implements ID3_Field. Definition at line 1043 of file field.cpp. References GetType(), ID3FTY_BINARY, ID3FTY_INTEGER, ID3FTY_TEXTSTRING, Parse(), ParseBinary(), ParseInteger(), and ParseText(). Referenced by Parse(). |
|
Definition at line 195 of file field_binary.cpp. References ParseBinary(). Referenced by Parse(), and ParseBinary(). |
|
Definition at line 87 of file field_integer.cpp. References ID3_Reader::atEnd(), Clear(), ID3_Reader::getBeg(), ID3_Reader::getCur(), ID3_Reader::getEnd(), ParseInteger(), Set(), and Size(). Referenced by Parse(), and ParseInteger(). |
|
Definition at line 327 of file field_string_ascii.cpp. References AddText(), ID3_Reader::atEnd(), Clear(), ID3_Reader::getBeg(), ID3_Reader::getCur(), GetEncoding(), ID3_Reader::getEnd(), ID3_TextEnc, ID3FF_CSTR, ID3FF_LIST, ParseText(), ID3_Reader::remainingBytes(), SetText(), and Size(). Referenced by Parse(), and ParseText(). |
|
Implements ID3_Field. Definition at line 1112 of file field.cpp. References GetType(), ID3FTY_BINARY, ID3FTY_INTEGER, ID3FTY_TEXTSTRING, Render(), RenderBinary(), RenderInteger(), and RenderText(). Referenced by Render(). |
|
Definition at line 203 of file field_binary.cpp. References RenderBinary(), Size(), and ID3_Writer::writeChars(). Referenced by Render(), and RenderBinary(). |
|
Definition at line 105 of file field_integer.cpp. References RenderInteger(). Referenced by Render(), and RenderInteger(). |
|
Definition at line 376 of file field_string_ascii.cpp. References GetEncoding(), ID3_TextEnc, ID3FF_CSTR, and RenderText(). Referenced by Render(), and RenderText(). |
|
Definition at line 85 of file field_impl.h. |
|
Implements ID3_Field. Definition at line 39 of file field_binary.cpp. References GetType(), ID3FTY_BINARY, min, Set(), and uchar. |
|
Copies the supplied unicode string to the field. Performs similarly as the ASCII Set() method, taking a unicode_t string as a parameter rather than an ascii string.
Implements ID3_Field. Definition at line 49 of file field_string_unicode.cpp. References GetEncoding(), GetType(), ID3FTY_TEXTSTRING, ID3TE_UNICODE, and Set(). |
|
Copies the supplied string to the field. You may dispose of the source string after a call to this method. .
Implements ID3_Field. Definition at line 45 of file field_string_ascii.cpp. References GetType(), ID3FTY_TEXTSTRING, and Set(). |
|
Sets the value of the field to the specified integer.
Implements ID3_Field. Definition at line 47 of file field_integer.cpp. References Set(), and SetInteger(). Referenced by FromFile(), operator=(), ParseInteger(), and Set(). |
|
Copies the supplied unicode string to the field. Again, like the string types, the binary Set() function copies the data so you may dispose of the source data after a call to this method. Definition at line 55 of file field_binary.cpp. References Clear(), GetType(), ID3FTY_BINARY, and SetBinary(). Referenced by operator=(), and SetBinary(). |
|
Implements ID3_Field. Definition at line 1175 of file field.cpp. References GetEncoding(), ID3TE_NONE, ID3TE_NUMENCODINGS, IsEncodable(), and SetEncoding(). Referenced by operator=(), and SetEncoding(). |
|
Definition at line 52 of file field_integer.cpp. References Clear(), GetType(), ID3FTY_INTEGER, and SetInteger(). Referenced by operator=(), Set(), and SetInteger(). |
|
Definition at line 189 of file field_string_ascii.cpp. References GetType(), ID3FTY_TEXTSTRING, and SetText(). Referenced by operator=(), ParseText(), and SetText(). |
|
Returns the size of a field. The value returned is dependent on the type of the field. For ASCII strings, this returns the number of characters in the field, not including any NULL-terminator. The same holds true for Unicode---it returns the number of characters in the field, not bytes, and this does not include the Unicode BOM, which isn't put in a Unicode string obtained by the Get(unicode_t*, size_t, size_t) method anyway. For binary and integer fields, this returns the number of bytes in the field.
Implements ID3_Field. Definition at line 1018 of file field.cpp. References ID3FTY_INTEGER, and ID3FTY_TEXTSTRING. Referenced by BinSize(), Get(), ParseInteger(), ParseText(), RenderBinary(), and ToFile(). |
|
Copies binary data from the field to the specified file.
Implements ID3_Field. Definition at line 172 of file field_binary.cpp. References GetType(), ID3FTY_BINARY, NULL, Size(), and ToFile(). Referenced by ToFile(). |