clanCore XML

Classes

class  clan::DomAttr
 DOM Attribute class. More...
 
class  clan::DomCDATASection
 DOM CDATA Section. More...
 
class  clan::DomCharacterData
 DOM Character Data class. More...
 
class  clan::DomComment
 DOM Comment class. More...
 
class  clan::DomDocument
 DOM Document class. More...
 
class  clan::DomDocumentFragment
 DOM Document Fragment class. More...
 
class  clan::DomDocumentType
 DOM Document Type class. More...
 
class  clan::DomElement
 DOM Element class. More...
 
class  clan::DomEntity
 DOM Entity class. More...
 
class  clan::DomEntityReference
 DOM Entity Reference class. More...
 
class  clan::DomException
 DOM Exception class. More...
 
class  clan::DomImplementation
 DOM Implementation class. More...
 
class  clan::DomNamedNodeMap
 DOM Named Node Map class. More...
 
class  clan::DomNode
 DOM Node class. More...
 
class  clan::DomNodeList
 DOM Node List class. More...
 
class  clan::DomNotation
 DOM Notation class. More...
 
class  clan::DomProcessingInstruction
 DOM Processing Instruction class. More...
 
class  clan::DomText
 DOM Text class. More...
 
class  clan::XMLToken
 XML token in a XML file. More...
 
class  clan::XMLTokenizer
 The XML Tokenizer breaks a XML file into XML tokens. More...
 
class  clan::XMLWriter
 The XML Writer writes a XML file based on XML tokens. More...
 
class  clan::XPathEvaluator
 XPath evaluator. More...
 
class  clan::XPathObject
 XPath result object. More...
 

Typedefs

typedef std::string clan::DomString
 

Construction

 clan::DomAttr::DomAttr ()
 Constructs a DOM Attr handle. More...
 
 clan::DomAttr::DomAttr (DomDocument doc, const DomString &name, const DomString &namespace_uri=DomString())
 Constructs a DomAttr. More...
 
 clan::DomAttr::DomAttr (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomAttr. More...
 
 clan::DomAttr::~DomAttr ()
 

Attributes

DomString clan::DomAttr::get_name () const
 Returns the name of this attribute. More...
 
bool clan::DomAttr::get_specified () const
 If this attribute was explicitly given a value in the original document, this is true; otherwise, it is false. More...
 
DomString clan::DomAttr::get_value () const
 Returns the value of the attribute. More...
 
void clan::DomAttr::set_value (const DomString &value)
 Sets the value of the attribute. More...
 
DomElement clan::DomAttr::get_owner_element () const
 Returns the attribute's owner element. More...
 

Construction

 clan::DomCDATASection::DomCDATASection ()
 Constructs a DOM CDATA Section handle. More...
 
 clan::DomCDATASection::DomCDATASection (DomDocument &doc, const DomString &data)
 Constructs a DomCDATASection. More...
 
 clan::DomCDATASection::DomCDATASection (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomCDATASection. More...
 
 clan::DomCDATASection::~DomCDATASection ()
 

Construction

 clan::DomCharacterData::DomCharacterData ()
 Constructs a DOM CharacterData handle. More...
 
 clan::DomCharacterData::DomCharacterData (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomCharacterData. More...
 
 clan::DomCharacterData::~DomCharacterData ()
 

Attributes

unsigned long clan::DomCharacterData::get_length ()
 The number of characters that are available through data and the substringData method below. More...
 

Operations

DomString clan::DomCharacterData::substring_data (unsigned long offset, unsigned long count)
 Extracts a range of data from the node. More...
 
void clan::DomCharacterData::append_data (const DomString &arg)
 Append the string to the end of the character data of the node. More...
 
void clan::DomCharacterData::insert_data (unsigned long offset, const DomString &arg)
 Insert a string at the specified character offset. More...
 
void clan::DomCharacterData::delete_data (unsigned long offset, unsigned long count)
 Remove a range of characters from the node. More...
 
void clan::DomCharacterData::replace_data (unsigned long offset, unsigned long count, const DomString &arg)
 Replace the characters starting at the specified character offset with the specified string. More...
 

Implementation

 clan::DomCharacterData::DomCharacterData (DomDocument &doc, unsigned short node_type)
 Constructs a DomCharacterData. More...
 

Construction

 clan::DomComment::DomComment ()
 Constructs a DOM Comment handle. More...
 
 clan::DomComment::DomComment (DomDocument &doc, const DomString &data)
 Constructs a DomComment. More...
 
 clan::DomComment::DomComment (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomComment. More...
 
 clan::DomComment::~DomComment ()
 

Construction

 clan::DomDocument::DomDocument ()
 Constructs a DOM Document. More...
 
 clan::DomDocument::DomDocument (IODevice &input, bool eat_whitespace=true)
 Constructs a DomDocument. More...
 
 clan::DomDocument::DomDocument (const DomString &namespace_uri, const DomString &qualified_name, const DomDocumentType &doctype)
 
 clan::DomDocument::DomDocument (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomDocument. More...
 
 clan::DomDocument::~DomDocument ()
 

Attributes

DomDocumentType clan::DomDocument::get_doctype ()
 Returns the Document Type Declaration (see DomDocumentType)associated with this document. More...
 
DomImplementation clan::DomDocument::get_implementation ()
 Returns the DomImplementation object that handles this document. More...
 
DomElement clan::DomDocument::get_document_element ()
 Returns the root document element node. More...
 

Operations

DomElement clan::DomDocument::create_element (const DomString &tag_name)
 Creates an element of the type specified. More...
 
DomElement clan::DomDocument::create_element_ns (const DomString &namespace_uri, const DomString &qualified_name)
 Creates an element of the given qualified name and namespace URI. More...
 
DomDocumentFragment clan::DomDocument::create_document_fragment ()
 Creates an empty DocumentFragment object. More...
 
DomText clan::DomDocument::create_text_node (const DomString &data)
 Creates a Text node given the specified string. More...
 
DomComment clan::DomDocument::create_comment (const DomString &data)
 Creates a Comment node given the specified string. More...
 
DomCDATASection clan::DomDocument::create_cdata_section (const DomString &data)
 Creates a CDATASection node whose value is the specified string. More...
 
DomProcessingInstruction clan::DomDocument::create_processing_instruction (const DomString &target, const DomString &data)
 Creates a ProcessingInstruction node given the specified name and data strings. More...
 
DomAttr clan::DomDocument::create_attribute (const DomString &name)
 Creates an Attr of the given name. More...
 
DomAttr clan::DomDocument::create_attribute_ns (const DomString &namespace_uri, const DomString &qualified_name)
 Creates an attribute of the given qualified name and namespace URI. More...
 
DomEntityReference clan::DomDocument::create_entity_reference (const DomString &name)
 Creates an EntityReference object. More...
 
DomNodeList clan::DomDocument::get_elements_by_tag_name (const DomString &tag_name)
 Returns a NodeList of all the Elements with a given tag name. More...
 
DomNodeList clan::DomDocument::get_elements_by_tag_name_ns (const DomString &namespace_uri, const DomString &qualified_name)
 Returns a NodeList of all the Elements with a given local name and namespace URI. More...
 
DomElement clan::DomDocument::get_element_by_id (const DomString &element_id)
 Returns the Element whose ID is given by element_id. More...
 
DomNode clan::DomDocument::import_node (const DomNode &node, bool deep)
 Imports a node from another document to this document. More...
 
std::vector< DomNodeclan::DomDocument::load (IODevice &input, bool eat_whitespace=true, DomNode insert_point=DomNode())
 Loads the DOM document as XML from an input source. More...
 
void clan::DomDocument::save (IODevice &output, bool insert_whitespace=true)
 Saves the DOM document as XML to an input source. More...
 
void clan::DomDocument::clear_all ()
 Removes all nodes from the DOM document. More...
 

Construction

 clan::DomDocumentFragment::DomDocumentFragment ()
 Constructs a DOM Document Fragment handle. More...
 
 clan::DomDocumentFragment::DomDocumentFragment (DomDocument &doc)
 Constructs a DomDocumentFragment. More...
 
 clan::DomDocumentFragment::DomDocumentFragment (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomDocumentFragment. More...
 
 clan::DomDocumentFragment::~DomDocumentFragment ()
 

Construction

 clan::DomDocumentType::DomDocumentType ()
 Constructs a DOM Document Type handle. More...
 
 clan::DomDocumentType::DomDocumentType (const DomString &qualified_name, const DomString &public_id, const DomString &system_id)
 
 clan::DomDocumentType::DomDocumentType (DomDocument &doc)
 Constructs a DomDocumentType. More...
 
 clan::DomDocumentType::DomDocumentType (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomDocumentType. More...
 
 clan::DomDocumentType::~DomDocumentType ()
 

Attributes

DomString clan::DomDocumentType::get_name () const
 The name of DTD; i.e., the name immediately following the DOCTYPE keyword. More...
 
DomNamedNodeMap clan::DomDocumentType::get_entities () const
 A NamedNodeMap containing the general entities, both external and internal, declared in the DTD. More...
 
DomNamedNodeMap clan::DomDocumentType::get_notations () const
 A NamedNodeMap containing the notations declared in the DTD. More...
 
DomString clan::DomDocumentType::get_public_id () const
 The public identifier of the external subset. More...
 
DomString clan::DomDocumentType::get_system_id () const
 The system identifier of the external subset. More...
 
DomString clan::DomDocumentType::get_internal_subset () const
 The internal subset as a string. More...
 

Construction

 clan::DomElement::DomElement ()
 Constructs a DOM Element handle. More...
 
 clan::DomElement::DomElement (DomDocument &doc, const DomString &tag_name, const DomString &namespace_uri=DomString())
 
 clan::DomElement::DomElement (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomElement. More...
 
 clan::DomElement::~DomElement ()
 

Attributes

DomString clan::DomElement::get_tag_name () const
 Returns the name of the element. More...
 

Operations

bool clan::DomElement::has_attribute (const DomString &name) const
 Returns true if the element has the specified attribute. More...
 
bool clan::DomElement::has_attribute_ns (const DomString &namespace_uri, const DomString &local_name) const
 Returns true if the element has the specified attribute. More...
 
DomString clan::DomElement::get_attribute (const DomString &name) const
 Returns the specified attribute. More...
 
DomString clan::DomElement::get_attribute (const DomString &name, const DomString &default_value) const
 Get attribute. More...
 
DomString clan::DomElement::get_attribute_ns (const DomString &namespace_uri, const DomString &local_name) const
 Returns the specified attribute. More...
 
DomString clan::DomElement::get_attribute_ns (const DomString &namespace_uri, const DomString &local_name, const DomString &default_value) const
 
void clan::DomElement::set_attribute (const DomString &name, const DomString &value)
 Adds a new attribute. More...
 
void clan::DomElement::set_attribute_ns (const DomString &namespace_uri, const DomString &qualified_name, const DomString &value)
 
void clan::DomElement::remove_attribute (const DomString &name)
 Removes an attribute by name. More...
 
void clan::DomElement::remove_attribute_ns (const DomString &namespace_uri, const DomString &local_name)
 
DomAttr clan::DomElement::get_attribute_node (const DomString &name) const
 Get attribute node. More...
 
DomAttr clan::DomElement::get_attribute_node_ns (const DomString &namespace_uri, const DomString &local_name) const
 
DomAttr clan::DomElement::set_attribute_node (const DomAttr &attr)
 Set attribute node. More...
 
DomAttr clan::DomElement::set_attribute_node_ns (const DomAttr &attr)
 Set attribute node ns. More...
 
DomNodeList clan::DomElement::get_elements_by_tag_name (const DomString &name)
 Returns a NodeList of all descendant elements with a given tag name. More...
 
DomNodeList clan::DomElement::get_elements_by_tag_name_ns (const DomString &namespace_uri, const DomString &local_name)
 
std::string clan::DomElement::get_text () const
 Returns the text of all child Text nodes appended together. More...
 
DomString clan::DomElement::get_child_string (const DomString &name, const DomString &default_value=DomString()) const
 Returns the text value of the child node with the given tag name. More...
 
DomString clan::DomElement::get_child_string_ns (const DomString &namespace_uri, const DomString &local_name, const DomString &default_value=DomString()) const
 Returns the text value of the child node with the given local name and namespace. More...
 
int clan::DomElement::get_child_int (const DomString &name, int default_value=0) const
 Returns the integer value of the child node with the given tag name. More...
 
int clan::DomElement::get_child_int_ns (const DomString &namespace_uri, const DomString &local_name, int default_value=0) const
 Returns the integer value of the child node with the given local name and namespace. More...
 
bool clan::DomElement::get_child_bool (const DomString &name, bool default_value=false) const
 Returns the boolean value of the child node with the given tag name. More...
 
bool clan::DomElement::get_child_bool_ns (const DomString &namespace_uri, const DomString &local_name, bool default_value=false) const
 Returns the boolean value of the child node with the given local name and namespace. More...
 
void clan::DomElement::set_child_string (const DomString &name, const DomString &value)
 Sets the child node with the specified tag name to the given text value. More...
 
void clan::DomElement::set_child_string_ns (const DomString &namespace_uri, const DomString &qualified_name, const DomString &value)
 Sets the child node with the specified qualified name and namespace to the given text value. More...
 
void clan::DomElement::set_child_int (const DomString &name, int value)
 Sets the child node with the specified tag name to the given integer value. More...
 
void clan::DomElement::set_child_int_ns (const DomString &namespace_uri, const DomString &qualified_name, int value)
 Sets the child node with the specified qualified name and namespace to the given integer value. More...
 
void clan::DomElement::set_child_bool (const DomString &name, bool value)
 Sets the child node with the specified tag name to the given boolean value. More...
 
void clan::DomElement::set_child_bool_ns (const DomString &namespace_uri, const DomString &qualified_name, bool value)
 Sets the child node with the specified qualified name and namespace to the given boolean value. More...
 
DomElement clan::DomElement::get_first_child_element () const
 Returns the first child node that is an element node. More...
 
DomElement clan::DomElement::get_next_sibling_element () const
 Returns the next sibling node that is an element node. More...
 
int clan::DomElement::get_attribute_int (const DomString &name, int default_value=0) const
 Returns the integer value of the attribute node with the given tag name. More...
 
int clan::DomElement::get_attribute_int_ns (const DomString &namespace_uri, const DomString &local_name, int default_value=0) const
 Returns the integer value of the attribute node with the given local name and namespace. More...
 
bool clan::DomElement::get_attribute_bool (const DomString &name, bool default_value=false) const
 Returns the boolean value of the attribute node with the given tag name. More...
 
bool clan::DomElement::get_attribute_bool_ns (const DomString &namespace_uri, const DomString &local_name, bool default_value=false) const
 Returns the boolean value of the attribute node with the given local name and namespace. More...
 
float clan::DomElement::get_attribute_float (const DomString &name, float default_value=0.0f) const
 Returns the floating-point value of the attribute node with the given tag name. More...
 
float clan::DomElement::get_attribute_float_ns (const DomString &namespace_uri, const DomString &local_name, float default_value=0.0f) const
 Returns the floating-point value of the attribute node with the given local name and namespace. More...
 
void clan::DomElement::set_attribute_int (const DomString &name, int value)
 Sets the attribute node with the specified tag name to the given integer value. More...
 
void clan::DomElement::set_attribute_int_ns (const DomString &namespace_uri, const DomString &qualified_name, int value)
 Sets the attribute node with the specified qualified name and namespace to the given integer value. More...
 
void clan::DomElement::set_attribute_bool (const DomString &name, bool value)
 Sets the attribute node with the specified tag name to the given boolean value. More...
 
void clan::DomElement::set_attribute_bool_ns (const DomString &namespace_uri, const DomString &qualified_name, bool value)
 Sets the attribute node with the specified qualified name and namespace to the given boolean value. More...
 
void clan::DomElement::set_attribute_float (const DomString &name, float value, int num_decimal_places=6)
 Sets the attribute node with the specified tag name to the given floating-point value. More...
 
void clan::DomElement::set_attribute_float_ns (const DomString &namespace_uri, const DomString &qualified_name, float value, int num_decimal_places=6)
 Sets the attribute node with the specified qualified name and namespace to the given floating-point value. More...
 

Construction

 clan::DomEntity::DomEntity ()
 Constructs a DOM Entity handle. More...
 
 clan::DomEntity::DomEntity (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomEntity. More...
 
 clan::DomEntity::~DomEntity ()
 

Attributes

DomString clan::DomEntity::get_public_id () const
 The public identifier associated with the entity. More...
 
DomString clan::DomEntity::get_system_id () const
 The system identifier associated with the entity. More...
 
DomString clan::DomEntity::get_notation_name () const
 For unparsed entities, the name of the notation for the entity. More...
 

Construction

 clan::DomEntityReference::DomEntityReference ()
 Constructs a DOM Entity Reference handle. More...
 
 clan::DomEntityReference::DomEntityReference (DomDocument &doc, const DomString &name)
 Constructs a DomEntityReference. More...
 
 clan::DomEntityReference::DomEntityReference (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomEntityReference. More...
 
 clan::DomEntityReference::~DomEntityReference ()
 

Construction

 clan::DomException::DomException (unsigned short code)
 Constructs a DomException. More...
 
 clan::DomException::DomException (const std::string &message, unsigned short code)
 

Attributes

enum  clan::DomException::ExceptionCodes {
  clan::DomException::INDEX_SIZE_ERR = 1, clan::DomException::DOMSTRING_SIZE_ERR = 2, clan::DomException::HIERARCHY_REQUEST_ERR = 3, clan::DomException::WRONG_DOCUMENT_ERR = 4,
  clan::DomException::INVALID_CHARACTER_ERR = 5, clan::DomException::NO_DATA_ALLOWED_ERR = 6, clan::DomException::NO_MODIFICATION_ALLOWED_ERR = 7, clan::DomException::NOT_FOUND_ERR = 8,
  clan::DomException::NOT_SUPPORTED_ERR = 9, clan::DomException::INUSE_ATTRIBUTE_ERR = 10, clan::DomException::INVALID_STATE_ERR = 11, clan::DomException::SYNTAX_ERR = 12,
  clan::DomException::INVALID_MODIFICATION_ERR = 13, clan::DomException::NAMESPACE_ERR = 14, clan::DomException::INVALID_ACCESS_ERR = 15
}
 
unsigned short clan::DomException::code
 

Construction

 clan::DomImplementation::DomImplementation ()
 Constructs a DOM Implementation handle. More...
 
 clan::DomImplementation::DomImplementation (DomDocument &doc)
 Constructs a DomImplementation. More...
 
 clan::DomImplementation::~DomImplementation ()
 

Operations

bool clan::DomImplementation::has_feature (const DomString &feature, const DomString &version)
 Test if the DOM implementation implements a specific feature. More...
 
DomDocumentType clan::DomImplementation::create_document_type (const DomString &qualified_name, const DomString &public_id, const DomString &system_id)
 Creates an empty DocumentType node. More...
 
DomDocument clan::DomImplementation::create_document (const DomString &namespace_uri, const DomString &qualified_name, const DomDocumentType &doctype)
 Creates an XML Document object of the specified type with its document element. More...
 

Construction

 clan::DomNamedNodeMap::DomNamedNodeMap ()
 Constructs a DOM NamedNodeMap handle. More...
 
 clan::DomNamedNodeMap::DomNamedNodeMap (const DomNamedNodeMap &copy)
 Constructs a DomNamedNodeMap. More...
 
 clan::DomNamedNodeMap::~DomNamedNodeMap ()
 

Attributes

unsigned long clan::DomNamedNodeMap::get_length () const
 The number of nodes in the map. More...
 

Operations

DomNode clan::DomNamedNodeMap::get_named_item (const DomString &name) const
 Retrieves a node specified by name. More...
 
DomNode clan::DomNamedNodeMap::get_named_item_ns (const DomString &namespace_uri, const DomString &local_name) const
 Retrieves a node specified by namespace URI and local name. More...
 
DomNode clan::DomNamedNodeMap::set_named_item (const DomNode &node)
 Adds a node using its node name attribute. More...
 
DomNode clan::DomNamedNodeMap::set_named_item_ns (const DomNode &node)
 Adds a node using its namespace URI and local name. More...
 
DomNode clan::DomNamedNodeMap::remove_named_item (const DomString &name)
 Removes a node specified by name. More...
 
DomNode clan::DomNamedNodeMap::remove_named_item_ns (const DomString &namespace_uri, const DomString &local_name)
 Removes a node specified by namespace URI and local name. More...
 
DomNode clan::DomNamedNodeMap::item (unsigned long index) const
 Returns the indexth item in the map. More...
 

Implementation

std::shared_ptr< DomNamedNodeMap_Impl > clan::DomNamedNodeMap::impl
 
class clan::DomNamedNodeMap::DomNode
 
 clan::DomNamedNodeMap::DomNamedNodeMap (const std::shared_ptr< DomNamedNodeMap_Impl > &impl)
 Constructs a DomNamedNodeMap. More...
 

Construction

 clan::DomNode::DomNode ()
 
 clan::DomNode::DomNode (const DomNode &copy)
 Constructs a DomNode. More...
 
 clan::DomNode::~DomNode ()
 

Attributes

enum  clan::DomNode::NodeType {
  clan::DomNode::NULL_NODE = 0, clan::DomNode::ELEMENT_NODE = 1, clan::DomNode::ATTRIBUTE_NODE = 2, clan::DomNode::TEXT_NODE = 3,
  clan::DomNode::CDATA_SECTION_NODE = 4, clan::DomNode::ENTITY_REFERENCE_NODE = 5, clan::DomNode::ENTITY_NODE = 6, clan::DomNode::PROCESSING_INSTRUCTION_NODE = 7,
  clan::DomNode::COMMENT_NODE = 8, clan::DomNode::DOCUMENT_NODE = 9, clan::DomNode::DOCUMENT_TYPE_NODE = 10, clan::DomNode::DOCUMENT_FRAGMENT_NODE = 11,
  clan::DomNode::NOTATION_NODE = 12
}
 An integer indicating which type of node this is. More...
 
DomString clan::DomNode::get_node_name () const
 Returns the node name. More...
 
DomString clan::DomNode::get_namespace_uri () const
 Returns the namespace URI of this node. More...
 
DomString clan::DomNode::get_prefix () const
 Returns the namespace prefix of the node. More...
 
void clan::DomNode::set_prefix (const DomString &prefix)
 Sets the namespace prefix of the node. More...
 
DomString clan::DomNode::get_local_name () const
 Returns local part of the qualified name of this node. More...
 
DomString clan::DomNode::get_node_value () const
 Returns the node value. More...
 
void clan::DomNode::set_node_value (const DomString &value)
 Sets the node value. More...
 
unsigned short clan::DomNode::get_node_type () const
 Returns the node type (one of those in the NodeType enum). More...
 
DomNode clan::DomNode::get_parent_node () const
 Returns the parent of this node. More...
 
DomNodeList clan::DomNode::get_child_nodes () const
 Returns a NodeList that contains all children of this node. More...
 
DomNode clan::DomNode::get_first_child () const
 The first child of this node. More...
 
DomNode clan::DomNode::get_last_child () const
 The last child of this node. More...
 
DomNode clan::DomNode::get_previous_sibling () const
 The node immediately preceding this node. More...
 
DomNode clan::DomNode::get_next_sibling () const
 The node immediately following this node. More...
 
DomNamedNodeMap clan::DomNode::get_attributes () const
 A NamedNodeMap containing the attributes of this node (if it is an Element) or null otherwise. More...
 
DomDocument clan::DomNode::get_owner_document () const
 The Document object associated with this node. More...
 
bool clan::DomNode::is_null () const
 Returns true if this is a null node. More...
 
bool clan::DomNode::is_element () const
 Returns true if this is an element node. More...
 
bool clan::DomNode::is_attr () const
 Returns true if this is an attribute node. More...
 
bool clan::DomNode::is_text () const
 Returns true if this is a text node. More...
 
bool clan::DomNode::is_cdata_section () const
 Returns true if this is a CDATA section node. More...
 
bool clan::DomNode::is_entity_reference () const
 Returns true if this is an entity reference node. More...
 
bool clan::DomNode::is_entity () const
 Returns true if this is an entity node. More...
 
bool clan::DomNode::is_processing_instruction () const
 Returns true if this is a processing instruction node. More...
 
bool clan::DomNode::is_comment () const
 Returns true if this is a comment node. More...
 
bool clan::DomNode::is_document () const
 Returns true if this is a document node. More...
 
bool clan::DomNode::is_document_type () const
 Returns true if this is a document type node. More...
 
bool clan::DomNode::is_document_fragment () const
 Returns true if this is a document fragment node. More...
 
bool clan::DomNode::is_notation () const
 Returns true if this is a notation node. More...
 
bool clan::DomNode::is_supported (const DomString &feature, const DomString &version) const
 Tests whether the DOM implementation implements a specific feature and that feature is supported by this node. More...
 
bool clan::DomNode::has_attributes () const
 Returns true if this node (if its an element) has any attributes. More...
 
bool clan::DomNode::has_child_nodes () const
 Returns true if this node has any children. More...
 

Operations

DomNodeclan::DomNode::operator= (const DomNode &copy)
 Copy assignment operator. More...
 
bool clan::DomNode::operator== (const DomNode &other) const
 Compare operator. More...
 
bool clan::DomNode::operator!= (const DomNode &other) const
 Compare operator. More...
 
void clan::DomNode::normalize ()
 Merges any adjacent Text nodes. More...
 
DomNode clan::DomNode::insert_before (DomNode &new_child, DomNode &ref_child)
 Inserts the node new_child before the existing child node ref_child. More...
 
DomNode clan::DomNode::replace_child (DomNode &new_child, DomNode &old_child)
 Replaces the child node old_child with new_child in the list of children. More...
 
DomNode clan::DomNode::remove_child (DomNode &old_child)
 Removes the child node indicated by old_child from the list of children, and returns it. More...
 
DomNode clan::DomNode::append_child (DomNode new_child)
 Adds the node new_child to the end of the list of children of this node. More...
 
DomNode clan::DomNode::clone_node (bool deep) const
 Returns a duplicate of this node, i.e., serves as a generic copy constructor for nodes. More...
 
DomElement clan::DomNode::to_element () const
 Returns the Element interface to this node. More...
 
DomAttr clan::DomNode::to_attr () const
 Returns the Attribute interface to this node. More...
 
DomText clan::DomNode::to_text () const
 Returns the Text interface to this node. More...
 
DomCDATASection clan::DomNode::to_cdata_section () const
 Returns the CDATA Section interface to this node. More...
 
DomEntityReference clan::DomNode::to_entity_reference () const
 Returns the Entity Reference interface to this node. More...
 
DomEntity clan::DomNode::to_entity () const
 Returns the Entity interface to this node. More...
 
DomProcessingInstruction clan::DomNode::to_processing_instruction () const
 Returns the Processing Instruction interface to this node. More...
 
DomComment clan::DomNode::to_comment () const
 Returns the Comment interface to this node. More...
 
DomDocument clan::DomNode::to_document () const
 Returns the Document interface to this node. More...
 
DomDocumentType clan::DomNode::to_document_type () const
 Returns the Document Type interface to this node. More...
 
DomDocumentFragment clan::DomNode::to_document_fragment () const
 Returns the Document Fragment interface to this node. More...
 
DomNotation clan::DomNode::to_notation () const
 Returns the Notation interface to this node. More...
 
DomNode clan::DomNode::named_item (const DomString &name) const
 Returns the first child node with the specified node name. More...
 
DomNode clan::DomNode::named_item_ns (const DomString &namespace_uri, const DomString &local_name) const
 Retrieves the first child node with the specified namespace URI and local name. More...
 
DomString clan::DomNode::find_namespace_uri (const DomString &qualified_name) const
 Searches the node tree upwards for the namespace URI of the given qualified name. More...
 
DomString clan::DomNode::find_prefix (const DomString &namespace_uri) const
 Searches the node tree upwards for the prefix name for the namespace URI. More...
 
std::vector< DomNodeclan::DomNode::select_nodes (const DomString &xpath_expression) const
 Returns all the nodes matching the specified xpath expression using this node as the context node. More...
 
DomNode clan::DomNode::select_node (const DomString &xpath_expression) const
 Returns the first node matching the specified xpath expression using this node as the context node. More...
 
std::string clan::DomNode::select_string (const DomString &xpath_expression) const
 Returns the first node value matching the specified xpath expression using this node as the context node. More...
 
int clan::DomNode::select_int (const DomString &xpath_expression) const
 Returns the first node value (as integer) matching the specified xpath expression using this node as the context node. More...
 
float clan::DomNode::select_float (const DomString &xpath_expression) const
 Returns the first node value (as float) matching the specified xpath expression using this node as the context node. More...
 
bool clan::DomNode::select_bool (const DomString &xpath_expression) const
 Returns the first node value (as boolean) matching the specified xpath expression using this node as the context node. More...
 

Implementation

std::shared_ptr< DomNode_Impl > clan::DomNode::impl
 
class clan::DomNode::DomDocument
 
class clan::DomNode::DomNamedNodeMap
 
 clan::DomNode::DomNode (DomDocument doc, unsigned short node_type)
 Constructs a DomNode. More...
 
 clan::DomNode::DomNode (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomNode. More...
 

Construction

 clan::DomNodeList::DomNodeList ()
 Constructs a DOM NodeList handle. More...
 
 clan::DomNodeList::DomNodeList (DomNode &node, const DomString &tag_name)
 Constructs a DomNodeList. More...
 
 clan::DomNodeList::DomNodeList (DomNode &node, const DomString &namespace_uri, const DomString &name, bool local_name=false)
 
 clan::DomNodeList::~DomNodeList ()
 

Attributes

int clan::DomNodeList::get_length () const
 The number of nodes in the list. More...
 

Operations

DomNode clan::DomNodeList::item (unsigned long index) const
 Returns the indexth item in the collection. More...
 
void clan::DomNodeList::add_item (DomNode &to_add)
 Adds a DomNode to the list. More...
 

Construction

 clan::DomNotation::DomNotation ()
 Constructs a DOM Notation handle. More...
 
 clan::DomNotation::DomNotation (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomNotation. More...
 
 clan::DomNotation::~DomNotation ()
 

Attributes

DomString clan::DomNotation::get_public_id () const
 The public identifier of this notation. More...
 
DomString clan::DomNotation::get_system_id () const
 The system identifier of this notation. More...
 

Construction

 clan::DomProcessingInstruction::DomProcessingInstruction ()
 Constructs a DOM Processing Instruction handle. More...
 
 clan::DomProcessingInstruction::DomProcessingInstruction (DomDocument &doc, const DomString &target, const DomString &data)
 Constructs a DomProcessingInstruction. More...
 
 clan::DomProcessingInstruction::DomProcessingInstruction (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomProcessingInstruction. More...
 
 clan::DomProcessingInstruction::~DomProcessingInstruction ()
 

Attributes

DomString clan::DomProcessingInstruction::get_target () const
 The target of this processing instruction. More...
 
DomString clan::DomProcessingInstruction::get_data () const
 The content of this processing instruction. More...
 
void clan::DomProcessingInstruction::set_data (const DomString &data)
 Set data. More...
 

Construction

 clan::DomText::DomText ()
 Constructs a DOM Text handle. More...
 
 clan::DomText::DomText (DomDocument &doc, const DomString &data)
 Constructs a DomText. More...
 
 clan::DomText::DomText (const std::shared_ptr< DomNode_Impl > &impl)
 Constructs a DomText. More...
 
 clan::DomText::~DomText ()
 

Operations

DomText clan::DomText::split_text (unsigned long offset)
 Breaks this Text node into two Text nodes at the specified offset, keeping both in the tree as siblings. More...
 

Implementation

 clan::DomText::DomText (DomDocument &doc, unsigned short node_type)
 Constructs a DomText. More...
 

Construction

 clan::XMLToken::XMLToken ()
 

Attributes

enum  clan::XMLToken::TokenType {
  clan::XMLToken::NULL_TOKEN = 0, clan::XMLToken::ELEMENT_TOKEN = 1, clan::XMLToken::TEXT_TOKEN = 3, clan::XMLToken::CDATA_SECTION_TOKEN = 4,
  clan::XMLToken::ENTITY_REFERENCE_TOKEN = 5, clan::XMLToken::ENTITY_TOKEN = 6, clan::XMLToken::PROCESSING_INSTRUCTION_TOKEN = 7, clan::XMLToken::COMMENT_TOKEN = 8,
  clan::XMLToken::DOCUMENT_TYPE_TOKEN = 10, clan::XMLToken::NOTATION_TOKEN = 12
}
 
enum  clan::XMLToken::TokenVariant { clan::XMLToken::BEGIN = 1, clan::XMLToken::END = 2, clan::XMLToken::SINGLE = 3 }
 
typedef std::pair< std::string, std::string > clan::XMLToken::Attribute
 
TokenType clan::XMLToken::type
 The token type. More...
 
TokenVariant clan::XMLToken::variant
 The token variant. More...
 
std::string clan::XMLToken::name
 The name of the token. More...
 
std::string clan::XMLToken::value
 Returns the value of the token. More...
 
std::vector< Attributeclan::XMLToken::attributes
 All the attributes attached to the token. More...
 

Construction

 clan::XMLTokenizer::XMLTokenizer ()
 
 clan::XMLTokenizer::XMLTokenizer (const XMLTokenizer &copy)
 Constructs a XMLTokenizer. More...
 
 clan::XMLTokenizer::XMLTokenizer (IODevice &input)
 Constructs a XMLTokenizer. More...
 
virtual clan::XMLTokenizer::~XMLTokenizer ()
 

Attributes

bool clan::XMLTokenizer::get_eat_whitespace () const
 Returns true if eat whitespace flag is set. More...
 
void clan::XMLTokenizer::set_eat_whitespace (bool enable)
 If enabled, will eat any whitespace between tags. More...
 

Operations

XMLToken clan::XMLTokenizer::next ()
 Returns the next token available in input stream. More...
 
void clan::XMLTokenizer::next (XMLToken *out_token)
 Next. More...
 

Construction

 clan::XMLWriter::XMLWriter ()
 
 clan::XMLWriter::XMLWriter (const XMLWriter &copy)
 Constructs a XMLWriter. More...
 
 clan::XMLWriter::XMLWriter (IODevice &output)
 Constructs a XMLWriter. More...
 
virtual clan::XMLWriter::~XMLWriter ()
 

Attributes

bool clan::XMLWriter::get_insert_whitespace () const
 Returns the insert whitespace flag. More...
 
void clan::XMLWriter::set_insert_whitespace (bool enable)
 Inserts whitespace between tags if enabled. More...
 

Operations

void clan::XMLWriter::write (const XMLToken &token)
 Write token to file. More...
 

Construction

 clan::XPathEvaluator::XPathEvaluator ()
 

Operations

XPathObject clan::XPathEvaluator::evaluate (const std::string &expression, const DomNode &context_node) const
 Evaluate. More...
 

Constuction

 clan::XPathObject::XPathObject ()
 
 clan::XPathObject::XPathObject (bool value)
 
 clan::XPathObject::XPathObject (double value)
 
 clan::XPathObject::XPathObject (size_t value)
 
 clan::XPathObject::XPathObject (const std::string &value)
 
 clan::XPathObject::XPathObject (const std::vector< DomNode > &value)
 

Attributes

enum  clan::XPathObject::Type {
  clan::XPathObject::type_null, clan::XPathObject::type_node_set, clan::XPathObject::type_boolean, clan::XPathObject::type_number,
  clan::XPathObject::type_string
}
 
Type clan::XPathObject::get_type () const
 Get Type. More...
 
bool clan::XPathObject::is_null () const
 Is Null. More...
 
std::vector< DomNodeclan::XPathObject::get_node_set () const
 
bool clan::XPathObject::get_boolean () const
 Get Boolean. More...
 
double clan::XPathObject::get_number () const
 Get Number. More...
 
std::string clan::XPathObject::get_string () const
 Get String. More...
 

Operations

void clan::XPathObject::set_null ()
 Set null. More...
 
void clan::XPathObject::set_node_set (const std::vector< DomNode > &node_set)
 Set node set. More...
 
void clan::XPathObject::set_boolean (bool value)
 Set boolean. More...
 
void clan::XPathObject::set_number (double value)
 Set number. More...
 
void clan::XPathObject::set_string (const std::string &str)
 Set string. More...
 

Detailed Description

Typedef Documentation

◆ Attribute

typedef std::pair<std::string, std::string> clan::XMLToken::Attribute

◆ DomString

typedef std::string clan::DomString

Enumeration Type Documentation

◆ ExceptionCodes

Enumerator
INDEX_SIZE_ERR 
DOMSTRING_SIZE_ERR 
HIERARCHY_REQUEST_ERR 
WRONG_DOCUMENT_ERR 
INVALID_CHARACTER_ERR 
NO_DATA_ALLOWED_ERR 
NO_MODIFICATION_ALLOWED_ERR 
NOT_FOUND_ERR 
NOT_SUPPORTED_ERR 
INUSE_ATTRIBUTE_ERR 
INVALID_STATE_ERR 
SYNTAX_ERR 
INVALID_MODIFICATION_ERR 
NAMESPACE_ERR 
INVALID_ACCESS_ERR 

◆ NodeType

An integer indicating which type of node this is.

Enumerator
NULL_NODE 
ELEMENT_NODE 
ATTRIBUTE_NODE 
TEXT_NODE 
CDATA_SECTION_NODE 
ENTITY_REFERENCE_NODE 
ENTITY_NODE 
PROCESSING_INSTRUCTION_NODE 
COMMENT_NODE 
DOCUMENT_NODE 
DOCUMENT_TYPE_NODE 
DOCUMENT_FRAGMENT_NODE 
NOTATION_NODE 

◆ TokenType

Enumerator
NULL_TOKEN 
ELEMENT_TOKEN 
TEXT_TOKEN 
CDATA_SECTION_TOKEN 
ENTITY_REFERENCE_TOKEN 
ENTITY_TOKEN 
PROCESSING_INSTRUCTION_TOKEN 
COMMENT_TOKEN 
DOCUMENT_TYPE_TOKEN 
NOTATION_TOKEN 

◆ TokenVariant

Enumerator
BEGIN 
END 
SINGLE 

◆ Type

Enumerator
type_null 
type_node_set 
type_boolean 
type_number 
type_string 

Function Documentation

◆ DomAttr() [1/3]

clan::DomAttr::DomAttr ( )

Constructs a DOM Attr handle.

◆ DomAttr() [2/3]

clan::DomAttr::DomAttr ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomAttr.

Parameters
impl= Shared Ptr

◆ DomAttr() [3/3]

clan::DomAttr::DomAttr ( DomDocument  doc,
const DomString name,
const DomString namespace_uri = DomString() 
)

Constructs a DomAttr.

Parameters
doc= Dom Document
name= Dom String
namespace_uri= Dom String

◆ DomCDATASection() [1/3]

clan::DomCDATASection::DomCDATASection ( )

Constructs a DOM CDATA Section handle.

◆ DomCDATASection() [2/3]

clan::DomCDATASection::DomCDATASection ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomCDATASection.

Parameters
impl= Shared Ptr

◆ DomCDATASection() [3/3]

clan::DomCDATASection::DomCDATASection ( DomDocument doc,
const DomString data 
)

Constructs a DomCDATASection.

Parameters
doc= Dom Document
data= Dom String

◆ DomCharacterData() [1/3]

clan::DomCharacterData::DomCharacterData ( )

Constructs a DOM CharacterData handle.

◆ DomCharacterData() [2/3]

clan::DomCharacterData::DomCharacterData ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomCharacterData.

Parameters
impl= Shared Ptr

◆ DomCharacterData() [3/3]

clan::DomCharacterData::DomCharacterData ( DomDocument doc,
unsigned short  node_type 
)
protected

Constructs a DomCharacterData.

Parameters
doc= Dom Document
node_type= short

◆ DomComment() [1/3]

clan::DomComment::DomComment ( )

Constructs a DOM Comment handle.

◆ DomComment() [2/3]

clan::DomComment::DomComment ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomComment.

Parameters
impl= Shared Ptr

◆ DomComment() [3/3]

clan::DomComment::DomComment ( DomDocument doc,
const DomString data 
)

Constructs a DomComment.

Parameters
doc= Dom Document
data= Dom String

◆ DomDocument() [1/4]

clan::DomDocument::DomDocument ( )

Constructs a DOM Document.

◆ DomDocument() [2/4]

clan::DomDocument::DomDocument ( const DomString namespace_uri,
const DomString qualified_name,
const DomDocumentType doctype 
)

◆ DomDocument() [3/4]

clan::DomDocument::DomDocument ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomDocument.

Parameters
impl= Shared Ptr

◆ DomDocument() [4/4]

clan::DomDocument::DomDocument ( IODevice input,
bool  eat_whitespace = true 
)

Constructs a DomDocument.

Parameters
input= IODevice
eat_whitespace= bool

◆ DomDocumentFragment() [1/3]

clan::DomDocumentFragment::DomDocumentFragment ( )

Constructs a DOM Document Fragment handle.

◆ DomDocumentFragment() [2/3]

clan::DomDocumentFragment::DomDocumentFragment ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomDocumentFragment.

Parameters
impl= Shared Ptr

◆ DomDocumentFragment() [3/3]

clan::DomDocumentFragment::DomDocumentFragment ( DomDocument doc)

Constructs a DomDocumentFragment.

Parameters
doc= Dom Document

◆ DomDocumentType() [1/4]

clan::DomDocumentType::DomDocumentType ( )

Constructs a DOM Document Type handle.

◆ DomDocumentType() [2/4]

clan::DomDocumentType::DomDocumentType ( const DomString qualified_name,
const DomString public_id,
const DomString system_id 
)

◆ DomDocumentType() [3/4]

clan::DomDocumentType::DomDocumentType ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomDocumentType.

Parameters
impl= Shared Ptr

◆ DomDocumentType() [4/4]

clan::DomDocumentType::DomDocumentType ( DomDocument doc)

Constructs a DomDocumentType.

Parameters
doc= Dom Document

◆ DomElement() [1/3]

clan::DomElement::DomElement ( )

Constructs a DOM Element handle.

◆ DomElement() [2/3]

clan::DomElement::DomElement ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomElement.

Parameters
impl= Shared Ptr

◆ DomElement() [3/3]

clan::DomElement::DomElement ( DomDocument doc,
const DomString tag_name,
const DomString namespace_uri = DomString() 
)

◆ DomEntity() [1/2]

clan::DomEntity::DomEntity ( )

Constructs a DOM Entity handle.

◆ DomEntity() [2/2]

clan::DomEntity::DomEntity ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomEntity.

Parameters
impl= Shared Ptr

◆ DomEntityReference() [1/3]

clan::DomEntityReference::DomEntityReference ( )

Constructs a DOM Entity Reference handle.

◆ DomEntityReference() [2/3]

clan::DomEntityReference::DomEntityReference ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomEntityReference.

Parameters
impl= Shared Ptr

◆ DomEntityReference() [3/3]

clan::DomEntityReference::DomEntityReference ( DomDocument doc,
const DomString name 
)

Constructs a DomEntityReference.

Parameters
doc= Dom Document
name= Dom String

◆ DomException() [1/2]

clan::DomException::DomException ( const std::string &  message,
unsigned short  code 
)

◆ DomException() [2/2]

clan::DomException::DomException ( unsigned short  code)

Constructs a DomException.

Parameters
code= short

◆ DomImplementation() [1/2]

clan::DomImplementation::DomImplementation ( )

Constructs a DOM Implementation handle.

◆ DomImplementation() [2/2]

clan::DomImplementation::DomImplementation ( DomDocument doc)

Constructs a DomImplementation.

Parameters
doc= Dom Document

◆ DomNamedNodeMap() [1/3]

clan::DomNamedNodeMap::DomNamedNodeMap ( )

Constructs a DOM NamedNodeMap handle.

◆ DomNamedNodeMap() [2/3]

clan::DomNamedNodeMap::DomNamedNodeMap ( const DomNamedNodeMap copy)

Constructs a DomNamedNodeMap.

Parameters
copy= Dom Named Node Map

◆ DomNamedNodeMap() [3/3]

clan::DomNamedNodeMap::DomNamedNodeMap ( const std::shared_ptr< DomNamedNodeMap_Impl > &  impl)
protected

Constructs a DomNamedNodeMap.

Parameters
impl= Shared Ptr

◆ DomNode() [1/4]

clan::DomNode::DomNode ( )

◆ DomNode() [2/4]

clan::DomNode::DomNode ( const DomNode copy)

Constructs a DomNode.

Parameters
copy= Dom Node

◆ DomNode() [3/4]

clan::DomNode::DomNode ( const std::shared_ptr< DomNode_Impl > &  impl)
protected

Constructs a DomNode.

Parameters
impl= Shared Ptr

◆ DomNode() [4/4]

clan::DomNode::DomNode ( DomDocument  doc,
unsigned short  node_type 
)
protected

Constructs a DomNode.

Parameters
doc= Dom Document
node_type= short

◆ DomNodeList() [1/3]

clan::DomNodeList::DomNodeList ( )

Constructs a DOM NodeList handle.

◆ DomNodeList() [2/3]

clan::DomNodeList::DomNodeList ( DomNode node,
const DomString namespace_uri,
const DomString name,
bool  local_name = false 
)

◆ DomNodeList() [3/3]

clan::DomNodeList::DomNodeList ( DomNode node,
const DomString tag_name 
)

Constructs a DomNodeList.

Parameters
node= Dom Node
tag_name= Dom String

◆ DomNotation() [1/2]

clan::DomNotation::DomNotation ( )

Constructs a DOM Notation handle.

◆ DomNotation() [2/2]

clan::DomNotation::DomNotation ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomNotation.

Parameters
impl= Shared Ptr

◆ DomProcessingInstruction() [1/3]

clan::DomProcessingInstruction::DomProcessingInstruction ( )

Constructs a DOM Processing Instruction handle.

◆ DomProcessingInstruction() [2/3]

clan::DomProcessingInstruction::DomProcessingInstruction ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomProcessingInstruction.

Parameters
impl= Shared Ptr

◆ DomProcessingInstruction() [3/3]

clan::DomProcessingInstruction::DomProcessingInstruction ( DomDocument doc,
const DomString target,
const DomString data 
)

Constructs a DomProcessingInstruction.

Parameters
doc= Dom Document
target= Dom String
data= Dom String

◆ DomText() [1/4]

clan::DomText::DomText ( )

Constructs a DOM Text handle.

◆ DomText() [2/4]

clan::DomText::DomText ( const std::shared_ptr< DomNode_Impl > &  impl)

Constructs a DomText.

Parameters
impl= Shared Ptr

◆ DomText() [3/4]

clan::DomText::DomText ( DomDocument doc,
const DomString data 
)

Constructs a DomText.

Parameters
doc= Dom Document
data= Dom String

◆ DomText() [4/4]

clan::DomText::DomText ( DomDocument doc,
unsigned short  node_type 
)
protected

Constructs a DomText.

Parameters
doc= Dom Document
node_type= short

◆ XMLToken()

clan::XMLToken::XMLToken ( )
inline

◆ XMLTokenizer() [1/3]

clan::XMLTokenizer::XMLTokenizer ( )

◆ XMLTokenizer() [2/3]

clan::XMLTokenizer::XMLTokenizer ( const XMLTokenizer copy)

Constructs a XMLTokenizer.

Parameters
copy= XMLTokenizer

◆ XMLTokenizer() [3/3]

clan::XMLTokenizer::XMLTokenizer ( IODevice input)

Constructs a XMLTokenizer.

Parameters
input= IODevice

◆ XMLWriter() [1/3]

clan::XMLWriter::XMLWriter ( )

◆ XMLWriter() [2/3]

clan::XMLWriter::XMLWriter ( const XMLWriter copy)

Constructs a XMLWriter.

Parameters
copy= XMLWriter

◆ XMLWriter() [3/3]

clan::XMLWriter::XMLWriter ( IODevice output)

Constructs a XMLWriter.

Parameters
output= IODevice

◆ XPathEvaluator()

clan::XPathEvaluator::XPathEvaluator ( )

◆ XPathObject() [1/6]

clan::XPathObject::XPathObject ( )

◆ XPathObject() [2/6]

clan::XPathObject::XPathObject ( bool  value)

◆ XPathObject() [3/6]

clan::XPathObject::XPathObject ( const std::string &  value)

◆ XPathObject() [4/6]

clan::XPathObject::XPathObject ( const std::vector< DomNode > &  value)

◆ XPathObject() [5/6]

clan::XPathObject::XPathObject ( double  value)

◆ XPathObject() [6/6]

clan::XPathObject::XPathObject ( size_t  value)

◆ ~DomAttr()

clan::DomAttr::~DomAttr ( )

◆ ~DomCDATASection()

clan::DomCDATASection::~DomCDATASection ( )

◆ ~DomCharacterData()

clan::DomCharacterData::~DomCharacterData ( )

◆ ~DomComment()

clan::DomComment::~DomComment ( )

◆ ~DomDocument()

clan::DomDocument::~DomDocument ( )

◆ ~DomDocumentFragment()

clan::DomDocumentFragment::~DomDocumentFragment ( )

◆ ~DomDocumentType()

clan::DomDocumentType::~DomDocumentType ( )

◆ ~DomElement()

clan::DomElement::~DomElement ( )

◆ ~DomEntity()

clan::DomEntity::~DomEntity ( )

◆ ~DomEntityReference()

clan::DomEntityReference::~DomEntityReference ( )

◆ ~DomImplementation()

clan::DomImplementation::~DomImplementation ( )

◆ ~DomNamedNodeMap()

clan::DomNamedNodeMap::~DomNamedNodeMap ( )

◆ ~DomNode()

clan::DomNode::~DomNode ( )

◆ ~DomNodeList()

clan::DomNodeList::~DomNodeList ( )

◆ ~DomNotation()

clan::DomNotation::~DomNotation ( )

◆ ~DomProcessingInstruction()

clan::DomProcessingInstruction::~DomProcessingInstruction ( )

◆ ~DomText()

clan::DomText::~DomText ( )

◆ ~XMLTokenizer()

virtual clan::XMLTokenizer::~XMLTokenizer ( )
virtual

◆ ~XMLWriter()

virtual clan::XMLWriter::~XMLWriter ( )
virtual

◆ add_item()

void clan::DomNodeList::add_item ( DomNode to_add)

Adds a DomNode to the list.

◆ append_child()

DomNode clan::DomNode::append_child ( DomNode  new_child)

Adds the node new_child to the end of the list of children of this node.

If the new_child is already in the tree, it is first removed.

◆ append_data()

void clan::DomCharacterData::append_data ( const DomString arg)

Append the string to the end of the character data of the node.

◆ clear_all()

void clan::DomDocument::clear_all ( )

Removes all nodes from the DOM document.

◆ clone_node()

DomNode clan::DomNode::clone_node ( bool  deep) const

Returns a duplicate of this node, i.e., serves as a generic copy constructor for nodes.

The duplicate node has no parent.

Cloning an Element copies all attributes and their values, including those generated by the XML processor to represent defaulted attributes, but this method does not copy any text it contains unless it is a deep clone, since the text is contained in a child Text node. Cloning any other type of node simply returns a copy of this node.

Parameters
deepIf true, recursively clone the subtree under the specified node; if false, clone only the node itself (and its attributes, if it is an Element). retval: The duplicate node.

◆ create_attribute()

DomAttr clan::DomDocument::create_attribute ( const DomString name)

Creates an Attr of the given name.

Note that the Attr instance can then be set on an Element using the setAttribute method.

Parameters
nameThe name of the attribute.

◆ create_attribute_ns()

DomAttr clan::DomDocument::create_attribute_ns ( const DomString namespace_uri,
const DomString qualified_name 
)

Creates an attribute of the given qualified name and namespace URI.

Note that the Attr instance can then be set on an Element using the setAttribute method.

◆ create_cdata_section()

DomCDATASection clan::DomDocument::create_cdata_section ( const DomString data)

Creates a CDATASection node whose value is the specified string.

Parameters
dataThe data for the CDATASection contents.

◆ create_comment()

DomComment clan::DomDocument::create_comment ( const DomString data)

Creates a Comment node given the specified string.

Parameters
dataThe data for the node.

◆ create_document()

DomDocument clan::DomImplementation::create_document ( const DomString namespace_uri,
const DomString qualified_name,
const DomDocumentType doctype 
)

Creates an XML Document object of the specified type with its document element.

◆ create_document_fragment()

DomDocumentFragment clan::DomDocument::create_document_fragment ( )

Creates an empty DocumentFragment object.

◆ create_document_type()

DomDocumentType clan::DomImplementation::create_document_type ( const DomString qualified_name,
const DomString public_id,
const DomString system_id 
)

Creates an empty DocumentType node.

Entity declarations and notations are not made available. Entity reference expansions and default attribute additions do not occur. It is expected that a future version of the DOM will provide a way for populating a DocumentType.

◆ create_element()

DomElement clan::DomDocument::create_element ( const DomString tag_name)

Creates an element of the type specified.

Note that the instance returned implements the Element interface, so attributes can be specified directly on the returned object.

Parameters
tag_nameThe name of the element type to instantiate. For XML, this is case-sensitive.

◆ create_element_ns()

DomElement clan::DomDocument::create_element_ns ( const DomString namespace_uri,
const DomString qualified_name 
)

Creates an element of the given qualified name and namespace URI.

◆ create_entity_reference()

DomEntityReference clan::DomDocument::create_entity_reference ( const DomString name)

Creates an EntityReference object.

Parameters
nameThe name of the entity to reference.

◆ create_processing_instruction()

DomProcessingInstruction clan::DomDocument::create_processing_instruction ( const DomString target,
const DomString data 
)

Creates a ProcessingInstruction node given the specified name and data strings.

Parameters
targetThe target part of the processing instruction.
dataThe data for the node.

◆ create_text_node()

DomText clan::DomDocument::create_text_node ( const DomString data)

Creates a Text node given the specified string.

Parameters
dataThe data for the node.

◆ delete_data()

void clan::DomCharacterData::delete_data ( unsigned long  offset,
unsigned long  count 
)

Remove a range of characters from the node.

Parameters
offsetThe offset from which to remove characters.
countThe number of characters to delete. If the sum of offset and count exceeds length then all characters from offset to the end of the data are deleted.

◆ evaluate()

XPathObject clan::XPathEvaluator::evaluate ( const std::string &  expression,
const DomNode context_node 
) const

Evaluate.

Parameters
expression= String Ref
context_node= Dom Node
Returns
XPath Object

◆ find_namespace_uri()

DomString clan::DomNode::find_namespace_uri ( const DomString qualified_name) const

Searches the node tree upwards for the namespace URI of the given qualified name.

◆ find_prefix()

DomString clan::DomNode::find_prefix ( const DomString namespace_uri) const

Searches the node tree upwards for the prefix name for the namespace URI.

◆ get_attribute() [1/2]

DomString clan::DomElement::get_attribute ( const DomString name) const

Returns the specified attribute.

◆ get_attribute() [2/2]

DomString clan::DomElement::get_attribute ( const DomString name,
const DomString default_value 
) const

Get attribute.

Parameters
name= Dom String
default_value= Dom String
Returns
Dom String

◆ get_attribute_bool()

bool clan::DomElement::get_attribute_bool ( const DomString name,
bool  default_value = false 
) const

Returns the boolean value of the attribute node with the given tag name.

◆ get_attribute_bool_ns()

bool clan::DomElement::get_attribute_bool_ns ( const DomString namespace_uri,
const DomString local_name,
bool  default_value = false 
) const

Returns the boolean value of the attribute node with the given local name and namespace.

◆ get_attribute_float()

float clan::DomElement::get_attribute_float ( const DomString name,
float  default_value = 0.0f 
) const

Returns the floating-point value of the attribute node with the given tag name.

◆ get_attribute_float_ns()

float clan::DomElement::get_attribute_float_ns ( const DomString namespace_uri,
const DomString local_name,
float  default_value = 0.0f 
) const

Returns the floating-point value of the attribute node with the given local name and namespace.

◆ get_attribute_int()

int clan::DomElement::get_attribute_int ( const DomString name,
int  default_value = 0 
) const

Returns the integer value of the attribute node with the given tag name.

◆ get_attribute_int_ns()

int clan::DomElement::get_attribute_int_ns ( const DomString namespace_uri,
const DomString local_name,
int  default_value = 0 
) const

Returns the integer value of the attribute node with the given local name and namespace.

◆ get_attribute_node()

DomAttr clan::DomElement::get_attribute_node ( const DomString name) const

Get attribute node.

Parameters
name= Dom String
Returns
Dom Attr

◆ get_attribute_node_ns()

DomAttr clan::DomElement::get_attribute_node_ns ( const DomString namespace_uri,
const DomString local_name 
) const

◆ get_attribute_ns() [1/2]

DomString clan::DomElement::get_attribute_ns ( const DomString namespace_uri,
const DomString local_name 
) const

Returns the specified attribute.

◆ get_attribute_ns() [2/2]

DomString clan::DomElement::get_attribute_ns ( const DomString namespace_uri,
const DomString local_name,
const DomString default_value 
) const

◆ get_attributes()

DomNamedNodeMap clan::DomNode::get_attributes ( ) const

A NamedNodeMap containing the attributes of this node (if it is an Element) or null otherwise.

◆ get_boolean()

bool clan::XPathObject::get_boolean ( ) const

Get Boolean.

Returns
boolean

◆ get_child_bool()

bool clan::DomElement::get_child_bool ( const DomString name,
bool  default_value = false 
) const

Returns the boolean value of the child node with the given tag name.

Finds the first child node with the specified tag name, then returns the content of its first child text node as an boolean

◆ get_child_bool_ns()

bool clan::DomElement::get_child_bool_ns ( const DomString namespace_uri,
const DomString local_name,
bool  default_value = false 
) const

Returns the boolean value of the child node with the given local name and namespace.

Finds the first child node with the specified local name and namespace, then returns the content of its first child text node as an boolean

◆ get_child_int()

int clan::DomElement::get_child_int ( const DomString name,
int  default_value = 0 
) const

Returns the integer value of the child node with the given tag name.

Finds the first child node with the specified tag name, then returns the content of its first child text node as an integer

◆ get_child_int_ns()

int clan::DomElement::get_child_int_ns ( const DomString namespace_uri,
const DomString local_name,
int  default_value = 0 
) const

Returns the integer value of the child node with the given local name and namespace.

Finds the first child node with the specified local name and namespace, then returns the content of its first child text node as an integer

◆ get_child_nodes()

DomNodeList clan::DomNode::get_child_nodes ( ) const

Returns a NodeList that contains all children of this node.

If there are no children, this is a NodeList containing no nodes. The content of the returned NodeList is "live" in the sense that, for instance, changes to the children of the node object that it was created from are immediately reflected in the nodes returned by the NodeList accessors; it is not a static snapshot of the content of the node. This is true for every NodeList, including the ones returned by the getElementsByTagName method.

◆ get_child_string()

DomString clan::DomElement::get_child_string ( const DomString name,
const DomString default_value = DomString() 
) const

Returns the text value of the child node with the given tag name.

Finds the first child node with the specified tag name, then returns the content of its first child text node

◆ get_child_string_ns()

DomString clan::DomElement::get_child_string_ns ( const DomString namespace_uri,
const DomString local_name,
const DomString default_value = DomString() 
) const

Returns the text value of the child node with the given local name and namespace.

Finds the first child node with the specified local name and namespace, then returns the content of its first child text node

◆ get_data()

DomString clan::DomProcessingInstruction::get_data ( ) const

The content of this processing instruction.

This is from the first non white space character after the target to the character immediately preceding the ?>.

◆ get_doctype()

DomDocumentType clan::DomDocument::get_doctype ( )

Returns the Document Type Declaration (see DomDocumentType)associated with this document.

For HTML documents as well as XML documents without a document type declaration this returns null. The DOM Level 1 does not support editing the Document Type Declaration, therefore docType cannot be altered in any way.

◆ get_document_element()

DomElement clan::DomDocument::get_document_element ( )

Returns the root document element node.

This is a convenience attribute that allows direct access to the child node that is the root element of the document. For HTML documents, this is the element with the tag name "HTML".

◆ get_eat_whitespace()

bool clan::XMLTokenizer::get_eat_whitespace ( ) const

Returns true if eat whitespace flag is set.

◆ get_element_by_id()

DomElement clan::DomDocument::get_element_by_id ( const DomString element_id)

Returns the Element whose ID is given by element_id.

◆ get_elements_by_tag_name() [1/2]

DomNodeList clan::DomElement::get_elements_by_tag_name ( const DomString name)

Returns a NodeList of all descendant elements with a given tag name.

The descendant elements are returned in the order in which they would be encountered in a preorder traversal of the Element tree.

◆ get_elements_by_tag_name() [2/2]

DomNodeList clan::DomDocument::get_elements_by_tag_name ( const DomString tag_name)

Returns a NodeList of all the Elements with a given tag name.

The list is in the order in which they would be encountered in a preorder traversal of the Document tree.

Parameters
tag_nameThe name of the tag to match on. The special value "*" matches all tags.

◆ get_elements_by_tag_name_ns() [1/2]

DomNodeList clan::DomElement::get_elements_by_tag_name_ns ( const DomString namespace_uri,
const DomString local_name 
)

◆ get_elements_by_tag_name_ns() [2/2]

DomNodeList clan::DomDocument::get_elements_by_tag_name_ns ( const DomString namespace_uri,
const DomString qualified_name 
)

Returns a NodeList of all the Elements with a given local name and namespace URI.

The list is in the order in which they would be encountered in a preorder traversal of the Document tree.

◆ get_entities()

DomNamedNodeMap clan::DomDocumentType::get_entities ( ) const

A NamedNodeMap containing the general entities, both external and internal, declared in the DTD.

◆ get_first_child()

DomNode clan::DomNode::get_first_child ( ) const

The first child of this node.

If there is no such node, this returns a null node.

◆ get_first_child_element()

DomElement clan::DomElement::get_first_child_element ( ) const

Returns the first child node that is an element node.

◆ get_implementation()

DomImplementation clan::DomDocument::get_implementation ( )

Returns the DomImplementation object that handles this document.

◆ get_insert_whitespace()

bool clan::XMLWriter::get_insert_whitespace ( ) const

Returns the insert whitespace flag.

◆ get_internal_subset()

DomString clan::DomDocumentType::get_internal_subset ( ) const

The internal subset as a string.

Note: The actual content returned depends on how much information is available to the implementation. This may vary depending on various parameters, including the XML processor used to build the document.

◆ get_last_child()

DomNode clan::DomNode::get_last_child ( ) const

The last child of this node.

If there is no such node, this returns a null node.

◆ get_length() [1/3]

unsigned long clan::DomCharacterData::get_length ( )

The number of characters that are available through data and the substringData method below.

This may have the value zero, i.e., CharacterData nodes may be empty.

◆ get_length() [2/3]

unsigned long clan::DomNamedNodeMap::get_length ( ) const

The number of nodes in the map.

◆ get_length() [3/3]

int clan::DomNodeList::get_length ( ) const

The number of nodes in the list.

◆ get_local_name()

DomString clan::DomNode::get_local_name ( ) const

Returns local part of the qualified name of this node.

For nodes of any type other than ELEMENT_NODE and ATTRIBUTE_NODE and nodes created with a DOM Level 1 method, such as create_element from the Document interface, this is always an empty string.

◆ get_name() [1/2]

DomString clan::DomDocumentType::get_name ( ) const

The name of DTD; i.e., the name immediately following the DOCTYPE keyword.

◆ get_name() [2/2]

DomString clan::DomAttr::get_name ( ) const

Returns the name of this attribute.

◆ get_named_item()

DomNode clan::DomNamedNodeMap::get_named_item ( const DomString name) const

Retrieves a node specified by name.

◆ get_named_item_ns()

DomNode clan::DomNamedNodeMap::get_named_item_ns ( const DomString namespace_uri,
const DomString local_name 
) const

Retrieves a node specified by namespace URI and local name.

◆ get_namespace_uri()

DomString clan::DomNode::get_namespace_uri ( ) const

Returns the namespace URI of this node.

◆ get_next_sibling()

DomNode clan::DomNode::get_next_sibling ( ) const

The node immediately following this node.

If there is no such node, this returns a null node.

◆ get_next_sibling_element()

DomElement clan::DomElement::get_next_sibling_element ( ) const

Returns the next sibling node that is an element node.

◆ get_node_name()

DomString clan::DomNode::get_node_name ( ) const

Returns the node name.

The return value vary according to the node type as follows:

  • Element: name of tag
  • Attr: name of attribute
  • Text: "#text"
  • CDataSection: "#cdata-section"
  • EntityReference: name of entity referenced
  • Entity: entity name
  • ProcessingInstruction: target
  • Comment: "#comment"
  • Document: "#document"
  • DocumentType: document type name
  • DocumentFragment: "#document-fragment"
  • Notation: notation name

◆ get_node_set()

std::vector<DomNode> clan::XPathObject::get_node_set ( ) const

◆ get_node_type()

unsigned short clan::DomNode::get_node_type ( ) const

Returns the node type (one of those in the NodeType enum).

◆ get_node_value()

DomString clan::DomNode::get_node_value ( ) const

Returns the node value.

The return value vary according to the node type as follows:

  • Element: null
  • Attr: value of attribute
  • Text: content of text node
  • CDataSection: content of CDATA Section
  • EntityReference: null
  • Entity: null
  • ProcessingInstruction: entire content excluding the target
  • Comment: content of the comment
  • Document: null
  • DocumentType: null
  • DocumentFragment: null
  • Notation: null

◆ get_notation_name()

DomString clan::DomEntity::get_notation_name ( ) const

For unparsed entities, the name of the notation for the entity.

For parsed entities, this is null.

◆ get_notations()

DomNamedNodeMap clan::DomDocumentType::get_notations ( ) const

A NamedNodeMap containing the notations declared in the DTD.

◆ get_number()

double clan::XPathObject::get_number ( ) const

Get Number.

Returns
number

◆ get_owner_document()

DomDocument clan::DomNode::get_owner_document ( ) const

The Document object associated with this node.

This is also the Document object used to create new nodes. When this node is a Document this is null.

◆ get_owner_element()

DomElement clan::DomAttr::get_owner_element ( ) const

Returns the attribute's owner element.

The Element node this attribute is attached to or null if this attribute is not in use.

◆ get_parent_node()

DomNode clan::DomNode::get_parent_node ( ) const

Returns the parent of this node.

All nodes, except Document, DocumentFragment, and Attr may have a parent. However, if a node has just been created and not yet added to the tree, or if it has been removed from the tree, this is null.

◆ get_prefix()

DomString clan::DomNode::get_prefix ( ) const

Returns the namespace prefix of the node.

For nodes of any type other than ELEMENT_NODE and ATTRIBUTE_NODE and nodes created with a DOM Level 1 method, such as create_element from the Document interface, this is always an empty string.

◆ get_previous_sibling()

DomNode clan::DomNode::get_previous_sibling ( ) const

The node immediately preceding this node.

If there is no such node, this returns a null node.

◆ get_public_id() [1/3]

DomString clan::DomEntity::get_public_id ( ) const

The public identifier associated with the entity.

If the public identifier was not specified, this is null.

◆ get_public_id() [2/3]

DomString clan::DomNotation::get_public_id ( ) const

The public identifier of this notation.

If the public identifier was not specified, this is null.

◆ get_public_id() [3/3]

DomString clan::DomDocumentType::get_public_id ( ) const

The public identifier of the external subset.

◆ get_specified()

bool clan::DomAttr::get_specified ( ) const

If this attribute was explicitly given a value in the original document, this is true; otherwise, it is false.

  • If the attribute has an assigned value in the document then specified is true, and the value is the assigned value.
  • If the attribute has no assigned value in the document and has a default value in the DTD, then specified is false, and the value is the default value in the DTD.
  • If the attribute has no assigned value in the document and has a value of #IMPLIED in the DTD, then the attribute does not appear in the structure model of the document.

◆ get_string()

std::string clan::XPathObject::get_string ( ) const

Get String.

Returns
string

◆ get_system_id() [1/3]

DomString clan::DomEntity::get_system_id ( ) const

The system identifier associated with the entity.

If the system identifier was not specified, this is null.

◆ get_system_id() [2/3]

DomString clan::DomNotation::get_system_id ( ) const

The system identifier of this notation.

If the system identifier was not specified, this is null.

◆ get_system_id() [3/3]

DomString clan::DomDocumentType::get_system_id ( ) const

The system identifier of the external subset.

◆ get_tag_name()

DomString clan::DomElement::get_tag_name ( ) const

Returns the name of the element.

◆ get_target()

DomString clan::DomProcessingInstruction::get_target ( ) const

The target of this processing instruction.

XML defines this as being the first token following the markup that begins the processing instruction.

◆ get_text()

std::string clan::DomElement::get_text ( ) const

Returns the text of all child Text nodes appended together.

◆ get_type()

Type clan::XPathObject::get_type ( ) const

Get Type.

Returns
type

◆ get_value()

DomString clan::DomAttr::get_value ( ) const

Returns the value of the attribute.

◆ has_attribute()

bool clan::DomElement::has_attribute ( const DomString name) const

Returns true if the element has the specified attribute.

◆ has_attribute_ns()

bool clan::DomElement::has_attribute_ns ( const DomString namespace_uri,
const DomString local_name 
) const

Returns true if the element has the specified attribute.

◆ has_attributes()

bool clan::DomNode::has_attributes ( ) const

Returns true if this node (if its an element) has any attributes.

◆ has_child_nodes()

bool clan::DomNode::has_child_nodes ( ) const

Returns true if this node has any children.

◆ has_feature()

bool clan::DomImplementation::has_feature ( const DomString feature,
const DomString version 
)

Test if the DOM implementation implements a specific feature.

Parameters
featureThe package name of the feature to test. In Level 1, the legal values are "HTML" and "XML" (case-insensitive).
versionThis is the version number of the package name to test. In Level 1, this is the string "1.0". If the version is not specified, supporting any version of the feature will cause the method to return true. retval: true if the feature is implemented in the specified version, false otherwise.

◆ import_node()

DomNode clan::DomDocument::import_node ( const DomNode node,
bool  deep 
)

Imports a node from another document to this document.

The returned node has no parent. The source node is not altered or removed from the original document; this method creates a new copy of the source node.

For all nodes, importing a node creates a node object owned by the importing document, with attribute values identical to the source node's node_name and node_type, plus the attributes related to namespaces (prefix, local_name, and namespace_uri). As in the clone_node operation on a Node, the source node is not altered.

◆ insert_before()

DomNode clan::DomNode::insert_before ( DomNode new_child,
DomNode ref_child 
)

Inserts the node new_child before the existing child node ref_child.

If refChild is a null node, inserts new_child at the end of the list of children.

If newChild is a DocumentFragment object, all of its children are inserted, in the same order, before ref_child. If the new_child is already in the tree, it is first removed.

Parameters
new_childThe node to insert.
ref_childThe reference node, i.e., the node before which the new node must be inserted. retval: The node being inserted.

◆ insert_data()

void clan::DomCharacterData::insert_data ( unsigned long  offset,
const DomString arg 
)

Insert a string at the specified character offset.

Parameters
offsetThe character offset at which to insert.
argThe DOMString to insert.

◆ is_attr()

bool clan::DomNode::is_attr ( ) const

Returns true if this is an attribute node.

◆ is_cdata_section()

bool clan::DomNode::is_cdata_section ( ) const

Returns true if this is a CDATA section node.

◆ is_comment()

bool clan::DomNode::is_comment ( ) const

Returns true if this is a comment node.

◆ is_document()

bool clan::DomNode::is_document ( ) const

Returns true if this is a document node.

◆ is_document_fragment()

bool clan::DomNode::is_document_fragment ( ) const

Returns true if this is a document fragment node.

◆ is_document_type()

bool clan::DomNode::is_document_type ( ) const

Returns true if this is a document type node.

◆ is_element()

bool clan::DomNode::is_element ( ) const

Returns true if this is an element node.

◆ is_entity()

bool clan::DomNode::is_entity ( ) const

Returns true if this is an entity node.

◆ is_entity_reference()

bool clan::DomNode::is_entity_reference ( ) const

Returns true if this is an entity reference node.

◆ is_notation()

bool clan::DomNode::is_notation ( ) const

Returns true if this is a notation node.

◆ is_null() [1/2]

bool clan::XPathObject::is_null ( ) const

Is Null.

Returns
true = null

◆ is_null() [2/2]

bool clan::DomNode::is_null ( ) const

Returns true if this is a null node.

◆ is_processing_instruction()

bool clan::DomNode::is_processing_instruction ( ) const

Returns true if this is a processing instruction node.

◆ is_supported()

bool clan::DomNode::is_supported ( const DomString feature,
const DomString version 
) const

Tests whether the DOM implementation implements a specific feature and that feature is supported by this node.

◆ is_text()

bool clan::DomNode::is_text ( ) const

Returns true if this is a text node.

◆ item() [1/2]

DomNode clan::DomNodeList::item ( unsigned long  index) const

Returns the indexth item in the collection.

If index is greater than or equal to the number of nodes in the list, this returns an empty node.

◆ item() [2/2]

DomNode clan::DomNamedNodeMap::item ( unsigned long  index) const

Returns the indexth item in the map.

If index is greater than or equal to the number of nodes in the map, this returns null.

◆ load()

std::vector<DomNode> clan::DomDocument::load ( IODevice input,
bool  eat_whitespace = true,
DomNode  insert_point = DomNode() 
)

Loads the DOM document as XML from an input source.

Parameters
inputInput source to read from.
eat_whitespacePassed on to XMLTokenizer::set_eat_whitespace.
insert_pointPlace in the DOM to insert the loaded XML code.
Returns
List of all top level nodes created.

◆ named_item()

DomNode clan::DomNode::named_item ( const DomString name) const

Returns the first child node with the specified node name.

Returns a null node if no child is found.

◆ named_item_ns()

DomNode clan::DomNode::named_item_ns ( const DomString namespace_uri,
const DomString local_name 
) const

Retrieves the first child node with the specified namespace URI and local name.

◆ next() [1/2]

XMLToken clan::XMLTokenizer::next ( )

Returns the next token available in input stream.

◆ next() [2/2]

void clan::XMLTokenizer::next ( XMLToken out_token)

Next.

Parameters
out_token= XMLToken

◆ normalize()

void clan::DomNode::normalize ( )

Merges any adjacent Text nodes.

Puts all Text nodes in the full depth of the sub-tree underneath this node, including attribute nodes, into a "normal" form where only structure (e.g., elements, comments, processing instructions, CDATA sections, and entity references) separates Text nodes, i.e., there are neither adjacent Text nodes nor empty Text nodes.

This can be used to ensure that the DOM view of a document is the same as if it were saved and re-loaded, and is useful when operations (such as XPointer lookups) that depend on a particular document tree structure are to be used.

Note: In cases where the document contains CDATASections, the normalize operation alone may not be sufficient, since XPointers do not differentiate between Text nodes and CDATASection nodes.

◆ operator!=()

bool clan::DomNode::operator!= ( const DomNode other) const

Compare operator.

◆ operator=()

DomNode& clan::DomNode::operator= ( const DomNode copy)

Copy assignment operator.

All objects in the DOM are handles to the underlying implementation. Therefore this doesn't actually copy contents between two DomNode's, but instead change the two DomNode's to point at the same node in the DOM.

◆ operator==()

bool clan::DomNode::operator== ( const DomNode other) const

Compare operator.

◆ remove_attribute()

void clan::DomElement::remove_attribute ( const DomString name)

Removes an attribute by name.

If the removed attribute has a default value it is immediately replaced.

◆ remove_attribute_ns()

void clan::DomElement::remove_attribute_ns ( const DomString namespace_uri,
const DomString local_name 
)

◆ remove_child()

DomNode clan::DomNode::remove_child ( DomNode old_child)

Removes the child node indicated by old_child from the list of children, and returns it.

◆ remove_named_item()

DomNode clan::DomNamedNodeMap::remove_named_item ( const DomString name)

Removes a node specified by name.

If the removed node is an Attr with a default value it is immediately replaced.

Parameters
nameThe name of a node to remove. retval: The node removed from the map or null if no node with such a name exists.

◆ remove_named_item_ns()

DomNode clan::DomNamedNodeMap::remove_named_item_ns ( const DomString namespace_uri,
const DomString local_name 
)

Removes a node specified by namespace URI and local name.

If the removed node is an Attr with a default value it is immediately replaced.

Returns
The node removed from the map or null if no node with such a name exists.

◆ replace_child()

DomNode clan::DomNode::replace_child ( DomNode new_child,
DomNode old_child 
)

Replaces the child node old_child with new_child in the list of children.

If the new_child is already in the tree, it is first removed.

Parameters
new_childThe new node to put in the child list.
old_childThe node being replaced in the list. retval: The node replaced.

◆ replace_data()

void clan::DomCharacterData::replace_data ( unsigned long  offset,
unsigned long  count,
const DomString arg 
)

Replace the characters starting at the specified character offset with the specified string.

Parameters
offsetThe offset from which to start replacing.
countThe number of characters to replace. If the sum of offset and count exceeds length, then all characters to the end of the data are replaced (i.e., the effect is the same as a remove method call with the same range, followed by an append method invocation).
argThe DOMString with which the range must be replaced.

◆ save()

void clan::DomDocument::save ( IODevice output,
bool  insert_whitespace = true 
)

Saves the DOM document as XML to an input source.

Parameters
outputOutput source to write to.
insert_whitespacePassed on to XMLWriter::set_insert_whitespace.

◆ select_bool()

bool clan::DomNode::select_bool ( const DomString xpath_expression) const

Returns the first node value (as boolean) matching the specified xpath expression using this node as the context node.

◆ select_float()

float clan::DomNode::select_float ( const DomString xpath_expression) const

Returns the first node value (as float) matching the specified xpath expression using this node as the context node.

◆ select_int()

int clan::DomNode::select_int ( const DomString xpath_expression) const

Returns the first node value (as integer) matching the specified xpath expression using this node as the context node.

◆ select_node()

DomNode clan::DomNode::select_node ( const DomString xpath_expression) const

Returns the first node matching the specified xpath expression using this node as the context node.

◆ select_nodes()

std::vector<DomNode> clan::DomNode::select_nodes ( const DomString xpath_expression) const

Returns all the nodes matching the specified xpath expression using this node as the context node.

◆ select_string()

std::string clan::DomNode::select_string ( const DomString xpath_expression) const

Returns the first node value matching the specified xpath expression using this node as the context node.

◆ set_attribute()

void clan::DomElement::set_attribute ( const DomString name,
const DomString value 
)

Adds a new attribute.

If an attribute with that name is already present in the element, its value is changed to be that of the value parameter.

This value is a simple string, it is not parsed as it is being set. So any markup (such as syntax to be recognized as an entity reference) is treated as literal text, and is appropriately escaped by the implementation when it is written out. In order to assign an attribute value that contains entity references, the user must create an Attr node plus any Text and EntityReference nodes, build the appropriate subtree, and use set_attribute_node to assign it as the value of an attribute.

◆ set_attribute_bool()

void clan::DomElement::set_attribute_bool ( const DomString name,
bool  value 
)

Sets the attribute node with the specified tag name to the given boolean value.

◆ set_attribute_bool_ns()

void clan::DomElement::set_attribute_bool_ns ( const DomString namespace_uri,
const DomString qualified_name,
bool  value 
)

Sets the attribute node with the specified qualified name and namespace to the given boolean value.

◆ set_attribute_float()

void clan::DomElement::set_attribute_float ( const DomString name,
float  value,
int  num_decimal_places = 6 
)

Sets the attribute node with the specified tag name to the given floating-point value.

◆ set_attribute_float_ns()

void clan::DomElement::set_attribute_float_ns ( const DomString namespace_uri,
const DomString qualified_name,
float  value,
int  num_decimal_places = 6 
)

Sets the attribute node with the specified qualified name and namespace to the given floating-point value.

◆ set_attribute_int()

void clan::DomElement::set_attribute_int ( const DomString name,
int  value 
)

Sets the attribute node with the specified tag name to the given integer value.

◆ set_attribute_int_ns()

void clan::DomElement::set_attribute_int_ns ( const DomString namespace_uri,
const DomString qualified_name,
int  value 
)

Sets the attribute node with the specified qualified name and namespace to the given integer value.

◆ set_attribute_node()

DomAttr clan::DomElement::set_attribute_node ( const DomAttr attr)

Set attribute node.

Parameters
attr= Dom Attr
Returns
Dom Attr

◆ set_attribute_node_ns()

DomAttr clan::DomElement::set_attribute_node_ns ( const DomAttr attr)

Set attribute node ns.

Parameters
attr= Dom Attr
Returns
Dom Attr

◆ set_attribute_ns()

void clan::DomElement::set_attribute_ns ( const DomString namespace_uri,
const DomString qualified_name,
const DomString value 
)

◆ set_boolean()

void clan::XPathObject::set_boolean ( bool  value)

Set boolean.

Parameters
value= bool

◆ set_child_bool()

void clan::DomElement::set_child_bool ( const DomString name,
bool  value 
)

Sets the child node with the specified tag name to the given boolean value.

Sets the first child node with the specified tag name, creating it if it does not exist, to the given boolean value

◆ set_child_bool_ns()

void clan::DomElement::set_child_bool_ns ( const DomString namespace_uri,
const DomString qualified_name,
bool  value 
)

Sets the child node with the specified qualified name and namespace to the given boolean value.

Sets the first child node with the specified qualified name and namespace, creating it if it does not exist, to the given boolean value

◆ set_child_int()

void clan::DomElement::set_child_int ( const DomString name,
int  value 
)

Sets the child node with the specified tag name to the given integer value.

Sets the first child node with the specified tag name, creating it if it does not exist, to the given integer value

◆ set_child_int_ns()

void clan::DomElement::set_child_int_ns ( const DomString namespace_uri,
const DomString qualified_name,
int  value 
)

Sets the child node with the specified qualified name and namespace to the given integer value.

Sets the first child node with the specified qualified name and namespace, creating it if it does not exist, to the given integer value

◆ set_child_string()

void clan::DomElement::set_child_string ( const DomString name,
const DomString value 
)

Sets the child node with the specified tag name to the given text value.

Sets the first child node with the specified tag name, creating it if it does not exist, to the given text value

◆ set_child_string_ns()

void clan::DomElement::set_child_string_ns ( const DomString namespace_uri,
const DomString qualified_name,
const DomString value 
)

Sets the child node with the specified qualified name and namespace to the given text value.

Sets the first child node with the specified qualified name and namespace, creating it if it does not exist, to the given text value

◆ set_data()

void clan::DomProcessingInstruction::set_data ( const DomString data)

Set data.

Parameters
data= Dom String

◆ set_eat_whitespace()

void clan::XMLTokenizer::set_eat_whitespace ( bool  enable)

If enabled, will eat any whitespace between tags.

◆ set_insert_whitespace()

void clan::XMLWriter::set_insert_whitespace ( bool  enable)

Inserts whitespace between tags if enabled.

◆ set_named_item()

DomNode clan::DomNamedNodeMap::set_named_item ( const DomNode node)

Adds a node using its node name attribute.

As the node name attribute is used to derive the name which the node must be stored under, multiple nodes of certain types (those that have a "special" string value) cannot be stored as the names would clash. This is seen as preferable to allowing nodes to be aliased.

Parameters
nodeA node to store in a named node map. The node will later be accessible using the value of the node name attribute of the node. If a node with that name is already present in the map, it is replaced by the new one. retval: If the new Node replaces an existing node with the same name the previously existing Node is returned, otherwise null is returned.

◆ set_named_item_ns()

DomNode clan::DomNamedNodeMap::set_named_item_ns ( const DomNode node)

Adds a node using its namespace URI and local name.

If a node with that namespace URI and that local name is already present in this map, it is replaced by the new one.

◆ set_node_set()

void clan::XPathObject::set_node_set ( const std::vector< DomNode > &  node_set)

Set node set.

Parameters
vector= Dom Node

◆ set_node_value()

void clan::DomNode::set_node_value ( const DomString value)

Sets the node value.

◆ set_null()

void clan::XPathObject::set_null ( )

Set null.

◆ set_number()

void clan::XPathObject::set_number ( double  value)

Set number.

Parameters
value= value

◆ set_prefix()

void clan::DomNode::set_prefix ( const DomString prefix)

Sets the namespace prefix of the node.

Note that setting this attribute, when permitted, changes the node_name attribute, which holds the qualified name, as well as the tag_name and name attributes of the Element and Attr interfaces, when applicable.

Note also that changing the prefix of an attribute that is known to have a default value, does not make a new attribute with the default value and the original prefix appear, since the namespace_uri and local_name do not change.

◆ set_string()

void clan::XPathObject::set_string ( const std::string &  str)

Set string.

Parameters
str= String Ref

◆ set_value()

void clan::DomAttr::set_value ( const DomString value)

Sets the value of the attribute.

◆ split_text()

DomText clan::DomText::split_text ( unsigned long  offset)

Breaks this Text node into two Text nodes at the specified offset, keeping both in the tree as siblings.

node then only contains all the content up to the offset point. And a new Text node, which is inserted as the next sibling of this node, contains all the content at and after the offset point.

Parameters
offsetThe offset at which to split. retval: The new Text node.

◆ substring_data()

DomString clan::DomCharacterData::substring_data ( unsigned long  offset,
unsigned long  count 
)

Extracts a range of data from the node.

Parameters
offsetStart offset of substring to extract.
countThe number of characters to extract. retval: The specified substring. If the sum of offset and count exceeds the length, then all characters to the end of the data are returned.

◆ to_attr()

DomAttr clan::DomNode::to_attr ( ) const

Returns the Attribute interface to this node.

If the node is not an Attribute node, then it returns a null node.

◆ to_cdata_section()

DomCDATASection clan::DomNode::to_cdata_section ( ) const

Returns the CDATA Section interface to this node.

If the node is not a CDATA Section node, then it returns a null node.

◆ to_comment()

DomComment clan::DomNode::to_comment ( ) const

Returns the Comment interface to this node.

If the node is not a Comment node, then it returns a null node.

◆ to_document()

DomDocument clan::DomNode::to_document ( ) const

Returns the Document interface to this node.

If the node is not a Document node, then it returns a null node.

◆ to_document_fragment()

DomDocumentFragment clan::DomNode::to_document_fragment ( ) const

Returns the Document Fragment interface to this node.

If the node is not a DocumentFragment node, then it returns a null node.

◆ to_document_type()

DomDocumentType clan::DomNode::to_document_type ( ) const

Returns the Document Type interface to this node.

If the node is not a Document Type node, then it returns a null node.

◆ to_element()

DomElement clan::DomNode::to_element ( ) const

Returns the Element interface to this node.

If the node is not an Element node, then it returns a null node.

◆ to_entity()

DomEntity clan::DomNode::to_entity ( ) const

Returns the Entity interface to this node.

If the node is not an Entity node, then it returns a null node.

◆ to_entity_reference()

DomEntityReference clan::DomNode::to_entity_reference ( ) const

Returns the Entity Reference interface to this node.

If the node is not an Entity Reference node, then it returns a null node.

◆ to_notation()

DomNotation clan::DomNode::to_notation ( ) const

Returns the Notation interface to this node.

If the node is not a Notation node, then it returns a null node.

◆ to_processing_instruction()

DomProcessingInstruction clan::DomNode::to_processing_instruction ( ) const

Returns the Processing Instruction interface to this node.

If the node is not a Processing Instrucion node, then it returns a null node.

◆ to_text()

DomText clan::DomNode::to_text ( ) const

Returns the Text interface to this node.

If the node is not a Text node, then it returns a null node.

◆ write()

void clan::XMLWriter::write ( const XMLToken token)

Write token to file.

Variable Documentation

◆ attributes

std::vector<Attribute> clan::XMLToken::attributes

All the attributes attached to the token.

◆ code

unsigned short clan::DomException::code

◆ impl [1/2]

std::shared_ptr<DomNamedNodeMap_Impl> clan::DomNamedNodeMap::impl
protected

◆ impl [2/2]

std::shared_ptr<DomNode_Impl> clan::DomNode::impl
protected

◆ name

std::string clan::XMLToken::name

The name of the token.

◆ type

TokenType clan::XMLToken::type

The token type.

◆ value

std::string clan::XMLToken::value

Returns the value of the token.

◆ variant

TokenVariant clan::XMLToken::variant

The token variant.

Friends

◆ DomDocument

friend class DomDocument
friend

◆ DomNamedNodeMap

friend class DomNamedNodeMap
friend

◆ DomNode

friend class DomNode
friend