Hold basic informations about an EBML element (ID + length). More...
#include <EbmlElement.h>

Public Member Functions | |
| EbmlElement (uint64 aDefaultSize, bool bValueSet=false) | |
| void | SetSizeLength (int NewSizeLength) |
| Set the minimum length that will be used to write the element size (-1 = optimal). | |
| int | GetSizeLength () const |
| EbmlElement * | FindNext (IOCallback &DataStream, uint64 MaxDataSize) |
| find the next element with the same ID | |
| EbmlElement * | SkipData (EbmlStream &DataStream, const EbmlSemanticContext &Context, EbmlElement *TestReadElt=NULL, bool AllowDummyElt=false) |
| virtual EbmlElement * | Clone () const =0 |
| Give a copy of the element, all data inside the element is copied. | |
| virtual | operator const EbmlId & () const =0 |
| virtual const EbmlCallbacks & | Generic () const =0 |
| return the generic callback to monitor a derived class | |
| virtual EbmlElement & | CreateElement () const =0 |
| virtual bool | SetSizeInfinite (bool bIsInfinite=true) |
| virtual bool | ValidateSize () const =0 |
| uint64 | GetElementPosition () const |
| uint64 | ElementSize (bool bWithDefault=false) const |
| filepos_t | Render (IOCallback &output, bool bWithDefault=false, bool bKeepPosition=false, bool bForceRender=false) |
| return the size of the header+data, before writing | |
| virtual filepos_t | UpdateSize (bool bWithDefault=false, bool bForceRender=false)=0 |
| virtual filepos_t | GetSize () const |
| update the Size of the Data stored | |
| virtual filepos_t | ReadData (IOCallback &input, ScopeMode ReadFully=SCOPE_ALL_DATA)=0 |
| return the size of the data stored in the element, on reading | |
| virtual void | Read (EbmlStream &inDataStream, const EbmlSemanticContext &Context, int &UpperEltFound, EbmlElement *&FoundElt, bool AllowDummyElt=false, ScopeMode ReadFully=SCOPE_ALL_DATA) |
| bool | IsLocked () const |
| void | Lock (bool bLock=true) |
| virtual bool | IsSmallerThan (const EbmlElement *Cmp) const |
| default comparison for elements that can't be compared | |
| virtual bool | IsDummy () const |
| virtual bool | IsMaster () const |
| uint8 | HeadSize () const |
| bool | ForceSize (uint64 NewSize) |
| return the size of the head, on reading/writing | |
| filepos_t | OverwriteHead (IOCallback &output, bool bKeepPosition=false) |
| uint32 | VoidMe (IOCallback &output, bool bWithDefault=false) |
| void the content of the element (replace by EbmlVoid) | |
| bool | DefaultISset () const |
| virtual bool | IsDefaultValue () const =0 |
| bool | IsFiniteSize () const |
| virtual void | SetDefaultSize (uint64 aDefaultSize) |
| set the default size of an element | |
| bool | ValueIsSet () const |
| uint64 | GetEndPosition () const |
Static Public Member Functions | |
| static EbmlElement * | FindNextElement (IOCallback &DataStream, const EbmlSemanticContext &Context, int &UpperLevel, uint64 MaxDataSize, bool AllowDummyElt, unsigned int MaxLowerLevel=1) |
| static EbmlElement * | FindNextID (IOCallback &DataStream, const EbmlCallbacks &ClassInfos, uint64 MaxDataSize) |
| static bool | CompareElements (const EbmlElement *A, const EbmlElement *B) |
Protected Member Functions | |
| filepos_t | RenderHead (IOCallback &output, bool bForceRender, bool bWithDefault=false, bool bKeepPosition=false) |
| filepos_t | MakeRenderHead (IOCallback &output, bool bKeepPosition) |
| virtual filepos_t | RenderData (IOCallback &output, bool bForceRender, bool bWithDefault=false)=0 |
| prepare the data before writing them (in case it's not already done by default) | |
| EbmlElement (const EbmlElement &ElementToClone) | |
| special constructor for cloning | |
| uint64 | GetDefaultSize () const |
| void | SetSize_ (uint64 aSize) |
| void | SetValueIsSet (bool Set=true) |
| void | SetDefaultIsSet (bool Set=true) |
| void | SetSizeIsFinite (bool Set=true) |
| uint64 | GetSizePosition () const |
Static Protected Member Functions | |
| static EbmlElement * | CreateElementUsingContext (const EbmlId &aID, const EbmlSemanticContext &Context, int &LowLevel, bool IsGlobalContext, bool bAllowDummy=false, unsigned int MaxLowerLevel=1) |
| find any element in the stream | |
Protected Attributes | |
| uint64 | Size |
| the size of the data to write | |
| uint64 | DefaultSize |
| Minimum data size to fill on rendering (0 = optimal). | |
| int | SizeLength |
| bool | bSizeIsFinite |
| the minimum size on which the size will be written (0 = optimal) | |
| uint64 | ElementPosition |
| uint64 | SizePosition |
| bool | bValueIsSet |
| bool | DefaultIsSet |
| bool | bLocked |
Hold basic informations about an EBML element (ID + length).
| virtual EbmlElement* EbmlElement::Clone | ( | ) | const [pure virtual] |
Give a copy of the element, all data inside the element is copied.
| EbmlElement * EbmlElement::CreateElementUsingContext | ( | const EbmlId & | aID, | |
| const EbmlSemanticContext & | Context, | |||
| int & | LowLevel, | |||
| bool | IsGlobalContext, | |||
| bool | bAllowDummy = false, |
|||
| unsigned int | MaxLowerLevel = 1 | |||
| ) | [static, protected] |
find any element in the stream
| EbmlElement * EbmlElement::FindNextElement | ( | IOCallback & | DataStream, | |
| const EbmlSemanticContext & | Context, | |||
| int & | UpperLevel, | |||
| uint64 | MaxDataSize, | |||
| bool | AllowDummyElt, | |||
| unsigned int | MaxLowerLevel = 1 | |||
| ) | [static] |
replace the new RawElement with the appropriate class (when known)
skip data for Dummy elements when they are not allowed
better check of the size checking for upper elements (using a list of size for each level)
| LowLevel | Will be returned with the level of the element found compared to the context given |
<
| EbmlElement * EbmlElement::FindNextID | ( | IOCallback & | DataStream, | |
| const EbmlCallbacks & | ClassInfos, | |||
| uint64 | MaxDataSize | |||
| ) | [static] |
| bool EbmlElement::ForceSize | ( | uint64 | NewSize | ) |
return the size of the head, on reading/writing
Force the size of an element
| filepos_t EbmlElement::Render | ( | IOCallback & | output, | |
| bool | bWithDefault = false, |
|||
| bool | bKeepPosition = false, |
|||
| bool | bForceRender = false | |||
| ) |
return the size of the header+data, before writing
| filepos_t EbmlElement::RenderHead | ( | IOCallback & | output, | |
| bool | bForceRender, | |||
| bool | bWithDefault = false, |
|||
| bool | bKeepPosition = false | |||
| ) | [protected] |
store the position of the Size writing for elements with unknown size
handle exceptions on errors
handle CodeSize bigger than 5 bytes
| EbmlElement * EbmlElement::SkipData | ( | EbmlStream & | DataStream, | |
| const EbmlSemanticContext & | Context, | |||
| EbmlElement * | TestReadElt = NULL, |
|||
| bool | AllowDummyElt = false | |||
| ) |
1.6.3