#include <Fl_XmlDoc.h>
Inheritance diagram for Fl_XmlDoc:
Public Methods | |
Fl_XmlDoc () | |
Constructs an empty document, without doctype. | |
Fl_XmlDoc (const char *name, const char *public_id=0, const char *system_id=0) | |
Constructs an empty document, with doctype. More... | |
virtual | ~Fl_XmlDoc () |
Destroys object and free's all resources. | |
virtual void | clear () |
Destroys all nodes in document. | |
Fl_XmlNode * | create_element (const char *tagname) |
Creates new named node of type Fl_XmlNode::DOM_ELEMENT. More... | |
Fl_XmlNode * | create_text (const char *data) |
Creates new named node of type Fl_XmlNode::DOM_TEXT. More... | |
Fl_XmlNode * | create_comment (const char *data) |
Creates new named node of type Fl_XmlNode::DOM_COMMENT. More... | |
Fl_XmlNode * | create_CDATA_section (const char *data) |
Creates new named node of type Fl_XmlNode::DOM_CDATA_SECTION. More... | |
Fl_XmlNode * | create_PI (const char *target, const char *data) |
Creates new named node of type Fl_XmlNode::DOM_PI. More... | |
Fl_XmlDocType & | doctype () |
Returns doctype of document. More... | |
const Fl_XmlDocType & | doctype () const |
Fl_XmlNode * | root_node () |
Returns pointer to root element of document. | |
void | save (Fl_Buffer &buffer) const |
Save document to buffer. More... | |
Static Public Methods | |
int | indent_spaces () |
Returns indentation in save. | |
void | indent_spaces (int i) |
Set indentation in save, defaults to 2. More... | |
Friends | |
class | Fl_XmlParser |
It provides access to document root node, which includes all nodes in XML document tree.
Since elements, text nodes, comments, processing instructions, etc... cannot exist outside the context of a document, the document class also contains the factory functions needed to create these objects.
The node objects created have an document() function which returns document which is used to create it. Creation of elements, text nodes, etc... Is done using the various factory functions provided in this class.
Definition at line 143 of file Fl_XmlDoc.h.
|
Constructs an empty document, with doctype.
|
|
Creates new named node of type Fl_XmlNode::DOM_CDATA_SECTION. It can be added to document DOM tree.
|
|
Creates new named node of type Fl_XmlNode::DOM_COMMENT. It can be added to document DOM tree.
|
|
Creates new named node of type Fl_XmlNode::DOM_ELEMENT. It can be added to document DOM tree.
|
|
Creates new named node of type Fl_XmlNode::DOM_PI. It can be added to document DOM tree.
|
|
Creates new named node of type Fl_XmlNode::DOM_TEXT. It can be added to document DOM tree.
|
|
Returns doctype of document. You can use it to add e.g. custom entities. mydoc->doctype().set_entity("myentity", "myreplacement"); Definition at line 217 of file Fl_XmlDoc.h. |
|
Set indentation in save, defaults to 2.
Definition at line 234 of file Fl_XmlDoc.h. |
|
Save document to buffer.
|