Thread portable class


Gate portable class


Timer class


Pool class


Terimber 2.0


About C++


Downloads Products & Services Support Clients Open Source About



Home / Open source / Terimber 2.0

xml_element Class Reference

base xml element More...

#include <sxml.h>

Inheritance diagram for xml_element:

xml_container xml_tree_node xml_node

List of all members.

Public Member Functions

 xml_element (const elementDecl *decl, xml_tree_node *parent)
 constructor
xml_forceinline bool has_attributes () const
 checks if element has attributes
xml_forceinline const elementDeclcast_decl () const
 casts to element declaration
xml_forceinline void clear ()
 clears element
xml_forceinline xml_tree_nodeadd_attribute (xml_tree_node *node)
 adds attribute to the tail
xml_forceinline xml_tree_nodeappend_attribute (xml_tree_node *after, xml_tree_node *node)
 appends attribute after node
xml_forceinline xml_tree_nodeinsert_attribute (xml_tree_node *before, xml_tree_node *node)
 inserts attribute before node
xml_forceinline xml_tree_noderemove_attribute (xml_tree_node *node)
 removes attribute

Static Public Member Functions

static xml_forceinline const
xml_element
cast_to_element (const xml_tree_node *x)
 casts to const element
static xml_forceinline
xml_element
cast_to_element (xml_tree_node *x)
 casts to the element

Public Attributes

xml_tree_node_first_attr
 pointer to the first attribute
xml_tree_node_last_attr
 pointer to the last attribute

Private Member Functions

 xml_element (const xml_element &x)
 private copy constructor and assign operator
xml_elementoperator= (const xml_element &x)


Detailed Description

base xml element

Definition at line 205 of file sxml.h.


Constructor & Destructor Documentation

xml_element::xml_element ( const xml_element x  )  [private]

private copy constructor and assign operator

prevents copying

xml_element::xml_element ( const elementDecl decl,
xml_tree_node parent 
)

constructor

Parameters:
decl  pointer to the node declaration
parent  pointer to the parent node

Definition at line 129 of file sxml.cpp.


Member Function Documentation

xml_element& xml_element::operator= ( const xml_element x  )  [private]

xml_forceinline bool xml_element::has_attributes (  )  const

checks if element has attributes

Definition at line 213 of file sxml.hpp.

References _first_attr.

Referenced by xml_designer_impl::has_attributes(), xml_persistor::persistElement(), and xml_document::validate_attributes().

xml_forceinline void xml_element::clear (  ) 

clears element

Reimplemented from xml_container.

Definition at line 234 of file sxml.hpp.

References _first_attr, _last_attr, and xml_container::clear().

Referenced by xml_document::clear(), and xml_document::clear_root().

xml_forceinline xml_element * xml_element::cast_to_element ( xml_tree_node x  )  [static]

casts to the element

Parameters:
x  pointer to the tree node

Definition at line 264 of file sxml.hpp.

References xml_node::_decl, ELEMENT_NODE, and nodeDecl::get_type().

xml_forceinline xml_tree_node * xml_element::add_attribute ( xml_tree_node node  ) 

adds attribute to the tail

Parameters:
node  pointer to the tree node

Definition at line 282 of file sxml.hpp.

References _first_attr, _last_attr, xml_tree_node::_left, and xml_tree_node::_right.

Referenced by xml_document::add_attribute().

xml_forceinline xml_tree_node * xml_element::append_attribute ( xml_tree_node after,
xml_tree_node node 
)

appends attribute after node

Parameters:
after  sibling node
node  attribute node

Definition at line 296 of file sxml.hpp.

References _last_attr, xml_tree_node::_left, and xml_tree_node::_right.

Referenced by xml_document::add_attribute().

xml_forceinline xml_tree_node * xml_element::insert_attribute ( xml_tree_node before,
xml_tree_node node 
)

inserts attribute before node

Parameters:
before  sibling node
node  attribute node

Definition at line 309 of file sxml.hpp.

References _first_attr, xml_tree_node::_left, and xml_tree_node::_right.

Referenced by xml_document::add_attribute().

xml_forceinline xml_tree_node * xml_element::remove_attribute ( xml_tree_node node  ) 

removes attribute

Parameters:
node  pointer to the attribute

Definition at line 319 of file sxml.hpp.

References _first_attr, _last_attr, xml_tree_node::_left, xml_tree_node::_parent, and xml_tree_node::_right.

Referenced by xml_designer_impl::remove_node().


Member Data Documentation


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


© Copyright Terimber 2003-.