Public Member Functions

xl7::xml::Document Class Reference

#include <Document.h>

Inheritance diagram for xl7::xml::Document:
xl7::xml::Node xl7::xml::Base

List of all members.

Public Member Functions

 Document (void)
virtual ~Document (void)
const Declarationget_declaration () const
const DocTypeDeclget_doc_type_decl () const
const StylesheetReferenceget_stylesheet_reference () const
const Elementget_root_element () const
Declarationget_declaration ()
DocTypeDeclget_doc_type_decl ()
StylesheetReferenceget_stylesheet_reference ()
Elementget_root_element ()
void reset (bool create_stub=true)
bool from_text (const cl7::string_type &xml_text)
Declarationset_declaration (const cl7::string_type &version, const cl7::string_type &encoding, const cl7::string_type &standalone)
DocTypeDeclset_doc_type_decl (const cl7::string_type &name, const cl7::string_type &decl)
StylesheetReferenceset_stylesheet_reference (const cl7::string_type &type, const cl7::string_type &href)
Elementset_root_element (const cl7::string_type &name)
Commentadd_comment (const cl7::string_type &value)
ProcessingInstructionadd_processing_instruction (const cl7::string_type &target, const cl7::string_type &value)
void remove_child_node (const Node *child_node)
void clear_child_nodes ()

Detailed Description

The (base) class representing an xml document "node".


Constructor & Destructor Documentation

xl7::xml::Document::Document ( void   ) 

Default constructor.

xl7::xml::Document::~Document ( void   )  [virtual]

Destructor.


Member Function Documentation

Comment * xl7::xml::Document::add_comment ( const cl7::string_type value  ) 

Adds a new comment to this document.

ProcessingInstruction * xl7::xml::Document::add_processing_instruction ( const cl7::string_type target,
const cl7::string_type value 
)

Adds a new processing instruction to this document.

void xl7::xml::Document::clear_child_nodes (  ) 

Clears (removes) all child nodes.

bool xl7::xml::Document::from_text ( const cl7::string_type xml_text  ) 

Parses the given xml text and manipulates this document object to represent the corresponding xml tree.

const Declaration* xl7::xml::Document::get_declaration (  )  const [inline]

Returns the declaration of this document.

Declaration* xl7::xml::Document::get_declaration (  )  [inline]

Returns the declaration of this document.

const DocTypeDecl* xl7::xml::Document::get_doc_type_decl (  )  const [inline]

Returns the document type declaration.

DocTypeDecl* xl7::xml::Document::get_doc_type_decl (  )  [inline]

Returns the document type declaration.

const Element* xl7::xml::Document::get_root_element (  )  const [inline]

Returns the root element of this document.

Element* xl7::xml::Document::get_root_element (  )  [inline]

Returns the root element of this document.

const StylesheetReference* xl7::xml::Document::get_stylesheet_reference (  )  const [inline]

Returns the stylesheet reference of this document.

StylesheetReference* xl7::xml::Document::get_stylesheet_reference (  )  [inline]

Returns the stylesheet reference of this document.

void xl7::xml::Document::remove_child_node ( const Node child_node  ) 

Removes the given child node from this document.

void xl7::xml::Document::reset ( bool  create_stub = true  ) 

Clears the document and all of its nodes and eventually (re-)creates a new xml "stub".

Declaration * xl7::xml::Document::set_declaration ( const cl7::string_type version,
const cl7::string_type encoding,
const cl7::string_type standalone 
)

Sets the properties of the declaration.

DocTypeDecl * xl7::xml::Document::set_doc_type_decl ( const cl7::string_type name,
const cl7::string_type decl 
)

Sets the properties of the document type declaration.

Element * xl7::xml::Document::set_root_element ( const cl7::string_type name  ) 

(Re-)creates the root element with the given name.

StylesheetReference * xl7::xml::Document::set_stylesheet_reference ( const cl7::string_type type,
const cl7::string_type href 
)

Sets the properties of the stylesheet reference.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines