Untouched text object intended for application parsing. More...
Public Member Functions | |
CData () | |
Create an empty CDATA object. | |
CData (const char *pCData) | |
Create a CDATA object with text. | |
virtual | ~CData () |
Call the destructor for a CDATA object. | |
virtual uint_t | Parse (InputMemoryStream *pInput) |
Parse an XML CDATA object. | |
virtual uint_t | Save (OutputMemoryStream *pOutput, uint_t uDepth) const |
Write out an XML CDATA object. | |
const char * | GetText (void) const |
Return a pointer to the contained CDATA string. | |
void | SetText (const char *pInput) |
Set a new CDATA string. | |
void | SetText (const String *pInput) |
Set a new CDATA string. | |
Public Member Functions inherited from Burger::FileXML::Generic | |
Generic (eType uType) | |
Initialize a generic object. | |
virtual | ~Generic () |
Call the destructor for a generic object. | |
Generic * | GetNext (void) const |
Get the pointer to the next object in the list. | |
Generic * | GetPrevious (void) const |
Get the pointer to the previous object in the list. | |
eType | GetType (void) const |
Get the enumeration of the derived class' type. | |
void | InsertBefore (Generic *pGeneric) |
Insert this object before this one in the linked list. | |
void | InsertAfter (Generic *pGeneric) |
Insert this object after this one in the linked list. | |
Element * | GetNextElement (void) const |
Follow the linked list of items to the next Element. | |
Element * | GetNextElement (const char *pElementName) const |
Follow the linked list of items to the next named Element. | |
Generic * | GetNextItem (void) const |
Follow the linked list of items to the next object. | |
Public Member Functions inherited from Burger::Base | |
const char * | get_class_name (void) const noexcept |
Get the name of the class. | |
virtual const Burger::StaticRTTI * | get_StaticRTTI (void) const noexcept |
Get the description to the class. | |
virtual | ~Base () noexcept=default |
Destructor. | |
Static Public Member Functions | |
static CData * | New (InputMemoryStream *pInput) |
Create a new CDATA structure and initialize it from an input file. | |
static CData * | New (const char *pCData) |
Create a new CDATA structure and initialize it with a string. | |
Private Attributes | |
String | m_CData |
Unmodified text for a CData line. | |
Additional Inherited Members | |
Public Types inherited from Burger::FileXML::Generic | |
enum | eType { XML_ROOT , XML_COMMENT , XML_CDATA , XML_ATTRIBUTE , XML_DECLARATION , XML_DOCUMENT , XML_ELEMENT , XML_TEXT , XML_UNKNOWN } |
Enumeration to identify derived classes. More... | |
Static Public Attributes inherited from Burger::Base | |
static const Burger::StaticRTTI | g_StaticRTTI |
The global description of the class. | |
Untouched text object intended for application parsing.
For every record in an XML file, store the text in one of these objects. It will not be translated and is retained so when the file is saved, the comments will be intact.
Burger::FileXML::CData::CData | ( | ) |
Create an empty CDATA object.
Burger::FileXML::CData::CData | ( | const char * | pCData | ) |
Create a CDATA object with text.
pCData | Text to store in this newly created object |
|
virtual |
Call the destructor for a CDATA object.
Unlink itself from the linked list and release the contained string
|
inline |
Return a pointer to the contained CDATA string.
|
static |
|
static |
Create a new CDATA structure and initialize it from an input file.
Parse the input file after the starting and up to and including the ending Will return NULL on a parsing error or if it's out of memory
pInput | Pointer to an input stream at the byte after the |
|
virtual |
Parse an XML CDATA object.
Given a data string that's starting right after the initial in an XML file, parse out the data and remove the trailing . Return an error if a ]]> was not found before the data stream was exhausted.
pInput | Pointer to the input text stream |
Reimplemented from Burger::FileXML::Generic.
|
virtual |
Write out an XML CDATA object.
Encapsulate a CDATA record with \n and send it out the data stream
pOutput | Pointer to the output text stream |
uDepth | Number of tabs to output for formatting before writing out the CDATA |
Reimplemented from Burger::FileXML::Generic.
|
inline |
Set a new CDATA string.
Replace the contained CDATA string with a new one
pInput | Pointer to a "C" string |
|
inline |
Set a new CDATA string.
Replace the contained CDATA string with a new one
pInput | Pointer to a String class instance |