ardour
Public Member Functions | Private Member Functions | Private Attributes | List of all members
XMLNode Class Reference

#include <xml++.h>

Public Member Functions

 XMLNode (const std::string &name)
 
 XMLNode (const std::string &name, const std::string &content)
 
 XMLNode (const XMLNode &other)
 
 ~XMLNode ()
 
XMLNodeoperator= (const XMLNode &other)
 
const std::string & name () const
 
bool is_content () const
 
const std::string & content () const
 
const std::string & set_content (const std::string &)
 
XMLNodeadd_content (const std::string &s=std::string())
 
const XMLNodeListchildren (const std::string &str=std::string()) const
 
XMLNodechild (const char *) const
 
XMLNodeadd_child (const char *)
 
XMLNodeadd_child_copy (const XMLNode &)
 
void add_child_nocopy (XMLNode &)
 
std::string attribute_value ()
 
const XMLPropertyListproperties () const
 
XMLPropertyproperty (const char *)
 
XMLPropertyproperty (const std::string &)
 
const XMLPropertyproperty (const char *n) const
 
const XMLPropertyproperty (const std::string &n) const
 
XMLPropertyadd_property (const char *name, const std::string &value)
 
XMLPropertyadd_property (const char *name, const char *value="")
 
XMLPropertyadd_property (const char *name, const long value)
 
void remove_property (const std::string &)
 
void remove_property_recursively (const std::string &)
 
void remove_nodes (const std::string &)
 
void remove_nodes_and_delete (const std::string &)
 
void remove_nodes_and_delete (const std::string &propname, const std::string &val)
 
void dump (std::ostream &, std::string p="") const
 

Private Member Functions

void clear_lists ()
 

Private Attributes

std::string _name
 
bool _is_content
 
std::string _content
 
XMLNodeList _children
 
XMLPropertyList _proplist
 
XMLPropertyMap _propmap
 
XMLNodeList _selected_children
 

Detailed Description

Definition at line 95 of file xml++.h.

Constructor & Destructor Documentation

XMLNode::XMLNode ( const std::string &  name)
XMLNode::XMLNode ( const std::string &  name,
const std::string &  content 
)
XMLNode::XMLNode ( const XMLNode other)

Definition at line 233 of file xml++.cc.

XMLNode::~XMLNode ( )

Definition at line 238 of file xml++.cc.

Member Function Documentation

XMLNode * XMLNode::add_child ( const char *  n)

Definition at line 351 of file xml++.cc.

XMLNode * XMLNode::add_child_copy ( const XMLNode n)

Definition at line 363 of file xml++.cc.

void XMLNode::add_child_nocopy ( XMLNode n)

Definition at line 357 of file xml++.cc.

XMLNode * XMLNode::add_content ( const std::string &  s = std::string())

Definition at line 407 of file xml++.cc.

XMLProperty* XMLNode::add_property ( const char *  name,
const std::string &  value 
)
XMLProperty * XMLNode::add_property ( const char *  name,
const char *  value = "" 
)

Definition at line 461 of file xml++.cc.

XMLProperty * XMLNode::add_property ( const char *  name,
const long  value 
)

Definition at line 468 of file xml++.cc.

std::string XMLNode::attribute_value ( )

Definition at line 396 of file xml++.cc.

XMLNode * XMLNode::child ( const char *  name) const

Definition at line 309 of file xml++.cc.

const XMLNodeList & XMLNode::children ( const std::string &  str = std::string()) const

Definition at line 329 of file xml++.cc.

void XMLNode::clear_lists ( )
private

Definition at line 244 of file xml++.cc.

const std::string& XMLNode::content ( ) const
inline

Definition at line 107 of file xml++.h.

void XMLNode::dump ( std::ostream &  ,
std::string  p = "" 
) const

Dump a node, its properties and children to a stream

Definition at line 669 of file xml++.cc.

bool XMLNode::is_content ( ) const
inline

Definition at line 106 of file xml++.h.

const std::string& XMLNode::name ( ) const
inline

Definition at line 104 of file xml++.h.

XMLNode & XMLNode::operator= ( const XMLNode other)

Definition at line 266 of file xml++.cc.

const XMLPropertyList& XMLNode::properties ( ) const
inline

Definition at line 119 of file xml++.h.

XMLProperty * XMLNode::property ( const char *  n)

Definition at line 413 of file xml++.cc.

XMLProperty* XMLNode::property ( const std::string &  )
const XMLProperty* XMLNode::property ( const char *  n) const
inline

Definition at line 122 of file xml++.h.

const XMLProperty* XMLNode::property ( const std::string &  n) const
inline

Definition at line 123 of file xml++.h.

void XMLNode::remove_nodes ( const std::string &  )

Remove all nodes with the name passed to remove_nodes

Definition at line 497 of file xml++.cc.

void XMLNode::remove_nodes_and_delete ( const std::string &  )

Remove and delete all nodes with the name passed to remove_nodes

void XMLNode::remove_nodes_and_delete ( const std::string &  propname,
const std::string &  val 
)

Remove and delete all nodes with property prop matching val

void XMLNode::remove_property ( const std::string &  )

Definition at line 476 of file xml++.cc.

void XMLNode::remove_property_recursively ( const std::string &  )

Remove any property with the given name from this node and its children

Definition at line 488 of file xml++.cc.

const string & XMLNode::set_content ( const std::string &  )

Definition at line 295 of file xml++.cc.

Member Data Documentation

XMLNodeList XMLNode::_children
private

Definition at line 145 of file xml++.h.

std::string XMLNode::_content
private

Definition at line 144 of file xml++.h.

bool XMLNode::_is_content
private

Definition at line 143 of file xml++.h.

std::string XMLNode::_name
private

Definition at line 142 of file xml++.h.

XMLPropertyList XMLNode::_proplist
private

Definition at line 146 of file xml++.h.

XMLPropertyMap XMLNode::_propmap
private

Definition at line 147 of file xml++.h.

XMLNodeList XMLNode::_selected_children
mutableprivate

Definition at line 148 of file xml++.h.


The documentation for this class was generated from the following files: