#include <frame_impl.h>
Public Types | |
typedef Fields::iterator | iterator |
typedef Fields::const_iterator | const_iterator |
Public Member Functions | |
ID3_FrameImpl (ID3_FrameID id=ID3FID_NOFRAME) | |
ID3_FrameImpl (const ID3_FrameHeader &) | |
ID3_FrameImpl (const ID3_Frame &) | |
virtual | ~ID3_FrameImpl () |
Destructor. | |
void | Clear () |
bool | SetID (ID3_FrameID id) |
ID3_FrameID | GetID () const |
ID3_Field * | GetField (ID3_FieldID name) const |
size_t | NumFields () const |
const char * | GetDescription () const |
const char * | GetTextID () const |
ID3_FrameImpl & | operator= (const ID3_Frame &) |
bool | HasChanged () const |
bool | Parse (ID3_Reader &) |
void | Render (ID3_Writer &) const |
size_t | Size () |
bool | Contains (ID3_FieldID fld) const |
bool | SetSpec (ID3_V2Spec) |
ID3_V2Spec | GetSpec () const |
bool | SetCompression (bool b) |
Sets the compression flag within the frame. | |
bool | GetCompression () const |
Returns whether or not the compression flag is set. | |
size_t | GetDataSize () const |
bool | SetEncryptionID (uchar id) |
uchar | GetEncryptionID () const |
bool | SetGroupingID (uchar id) |
uchar | GetGroupingID () const |
iterator | begin () |
iterator | end () |
const_iterator | begin () const |
const_iterator | end () const |
Static Public Member Functions | |
static const char * | GetDescription (ID3_FrameID) |
Protected Member Functions | |
bool | _SetID (ID3_FrameID) |
bool | _ClearFields () |
void | _InitFields () |
void | _InitFieldBits () |
void | _UpdateFieldDeps () |
Definition at line 41 of file frame_impl.h.
typedef Fields::iterator ID3_FrameImpl::iterator |
Definition at line 46 of file frame_impl.h.
typedef Fields::const_iterator ID3_FrameImpl::const_iterator |
Definition at line 47 of file frame_impl.h.
ID3_FrameImpl::ID3_FrameImpl | ( | ID3_FrameID | id = ID3FID_NOFRAME |
) |
ID3_FrameImpl::ID3_FrameImpl | ( | const ID3_FrameHeader & | ) |
ID3_FrameImpl::ID3_FrameImpl | ( | const ID3_Frame & | ) |
Definition at line 60 of file frame_impl.cpp.
ID3_FrameImpl::~ID3_FrameImpl | ( | ) | [virtual] |
void ID3_FrameImpl::Clear | ( | ) |
Definition at line 89 of file frame_impl.cpp.
References _ClearFields(), and ID3_FrameHeader::Clear().
Referenced by ~ID3_FrameImpl().
bool ID3_FrameImpl::SetID | ( | ID3_FrameID | id | ) |
Definition at line 121 of file frame_impl.cpp.
References _SetID(), and GetID().
Referenced by ID3_FrameImpl(), and operator=().
ID3_FrameID ID3_FrameImpl::GetID | ( | ) | const [inline] |
ID3_Field * ID3_FrameImpl::GetField | ( | ID3_FieldID | name | ) | const |
size_t ID3_FrameImpl::NumFields | ( | ) | const |
Definition at line 167 of file frame_impl.cpp.
const char * ID3_FrameImpl::GetDescription | ( | ) | const |
Definition at line 258 of file frame_impl.cpp.
References ID3_FrameHeader::GetFrameDef(), NULL, and ID3_FrameDef::sDescription.
const char * ID3_FrameImpl::GetDescription | ( | ID3_FrameID | ) | [static] |
Definition at line 248 of file frame_impl.cpp.
References ID3_FindFrameDef(), NULL, and ID3_FrameDef::sDescription.
const char* ID3_FrameImpl::GetTextID | ( | ) | const [inline] |
Definition at line 68 of file frame_impl.h.
References ID3_FrameHeader::GetTextID().
Referenced by Render().
ID3_FrameImpl & ID3_FrameImpl::operator= | ( | const ID3_Frame & | ) |
Definition at line 223 of file frame_impl.cpp.
References begin(), NULL, SetCompression(), SetEncryptionID(), SetGroupingID(), SetID(), and SetSpec().
bool ID3_FrameImpl::HasChanged | ( | ) | const |
Definition at line 207 of file frame_impl.cpp.
bool ID3_FrameImpl::Parse | ( | ID3_Reader & | ) |
Definition at line 109 of file frame_parse.cpp.
References _ClearFields(), _InitFields(), dami::io::WindowedReader::getBeg(), ID3_Reader::getBeg(), ID3_FrameHeader::GetCompression(), dami::io::WindowedReader::getCur(), ID3_Reader::getCur(), ID3_Header::GetDataSize(), ID3_FrameHeader::GetEncryption(), dami::io::WindowedReader::getEnd(), ID3_Reader::getEnd(), ID3_FrameHeader::GetGrouping(), ID3_FrameHeader::GetTextID(), ID3_FrameHeader::Parse(), dami::io::readBENumber(), dami::io::WindowedReader::readChar(), SetEncryptionID(), dami::io::ExitTrigger::setExitPos(), and SetGroupingID().
void ID3_FrameImpl::Render | ( | ID3_Writer & | ) | const |
Definition at line 71 of file frame_render.cpp.
References dami::io::CompressedWriter::flush(), ID3_FrameHeader::GetCompression(), ID3_FrameHeader::GetEncryption(), GetEncryptionID(), ID3_FrameHeader::GetGrouping(), GetGroupingID(), GetID(), dami::io::CompressedWriter::getOrigSize(), GetTextID(), ID3FID_NOFRAME, ID3_FrameHeader::Render(), ID3_FrameHeader::SetCompression(), ID3_Header::SetDataSize(), ID3_FrameHeader::SetEncryption(), ID3_FrameHeader::SetFrameID(), ID3_FrameHeader::SetGrouping(), ID3_FrameHeader::SetUnknownFrame(), ID3_FrameHeader::Size(), dami::io::writeBENumber(), ID3_Writer::writeChar(), and ID3_Writer::writeChars().
size_t ID3_FrameImpl::Size | ( | ) |
Definition at line 172 of file frame_impl.cpp.
References ID3FN_TEXTENC, ID3TE_ASCII, and ID3_FrameHeader::Size().
bool ID3_FrameImpl::Contains | ( | ID3_FieldID | fld | ) | const [inline] |
Definition at line 75 of file frame_impl.h.
bool ID3_FrameImpl::SetSpec | ( | ID3_V2Spec | ) |
Definition at line 140 of file frame_impl.cpp.
References ID3_Header::SetSpec().
Referenced by ID3_FrameImpl(), and operator=().
ID3_V2Spec ID3_FrameImpl::GetSpec | ( | ) | const |
bool ID3_FrameImpl::SetCompression | ( | bool | b | ) | [inline] |
Sets the compression flag within the frame.
When the compression flag is is set, compression will be attempted. However, the frame might not actually be compressed after it is rendered if the "compressed" data is no smaller than the "uncompressed" data.
Definition at line 85 of file frame_impl.h.
References ID3_FrameHeader::SetCompression().
Referenced by operator=().
bool ID3_FrameImpl::GetCompression | ( | ) | const [inline] |
Returns whether or not the compression flag is set.
After parsing a tag, this will indicate whether or not the frame was compressed. After rendering a tag, however, it does not actually indicate if the frame is compressed rendering. It only indicates whether or not compression was attempted. A frame will not be compressed, even whent the compression flag is set, if the "compressed" data is no smaller than the "uncompressed" data.
Definition at line 94 of file frame_impl.h.
References ID3_FrameHeader::GetCompression().
size_t ID3_FrameImpl::GetDataSize | ( | ) | const [inline] |
bool ID3_FrameImpl::SetEncryptionID | ( | uchar | id | ) | [inline] |
Definition at line 97 of file frame_impl.h.
References ID3_FrameHeader::SetEncryption().
Referenced by operator=(), and Parse().
uchar ID3_FrameImpl::GetEncryptionID | ( | ) | const [inline] |
bool ID3_FrameImpl::SetGroupingID | ( | uchar | id | ) | [inline] |
Definition at line 106 of file frame_impl.h.
References ID3_FrameHeader::SetGrouping().
Referenced by operator=(), and Parse().
uchar ID3_FrameImpl::GetGroupingID | ( | ) | const [inline] |
iterator ID3_FrameImpl::begin | ( | ) | [inline] |
iterator ID3_FrameImpl::end | ( | ) | [inline] |
Definition at line 117 of file frame_impl.h.
const_iterator ID3_FrameImpl::begin | ( | ) | const [inline] |
Definition at line 118 of file frame_impl.h.
const_iterator ID3_FrameImpl::end | ( | ) | const [inline] |
Definition at line 119 of file frame_impl.h.
bool ID3_FrameImpl::_SetID | ( | ID3_FrameID | ) | [protected] |
Definition at line 132 of file frame_impl.cpp.
References _ClearFields(), _InitFields(), and ID3_FrameHeader::SetFrameID().
Referenced by SetID().
bool ID3_FrameImpl::_ClearFields | ( | ) | [protected] |
void ID3_FrameImpl::_InitFields | ( | ) | [protected] |
Definition at line 97 of file frame_impl.cpp.
References ID3_FieldDef::_id, ID3_FrameDef::aeFieldDefs, ID3_FieldDef::DEFAULT, ID3_FrameHeader::GetFrameDef(), ID3_Field::GetID(), ID3FN_NOFIELD, and NULL.
Referenced by _SetID(), ID3_FrameImpl(), and Parse().
void ID3_FrameImpl::_InitFieldBits | ( | ) | [protected] |
void ID3_FrameImpl::_UpdateFieldDeps | ( | ) | [protected] |