## Class node

zeep::xml::node

## Synopsis

    // In header: <zeep/xml/node.hpp>

    class node {
    public:
      // types
      typedef element ;

      // construct/copy/destruct
      () = ;
      (node &) = ;
      (node &&) = ;
      node & (node &) = ;
      node & (node &&) = ;
      ~();

      // public member functions
       () ;
       () ;
       ();
       (, );
       () ;
       () ;
       () ;
       () ;

      () ;

      (, ) ;
       () ;
       () = ;
      element * ();
      element * () ;
      element * ();
      element * () ;
      node * ();
      node * () ;
      node * ();
      node * () ;
       (node *) ;
       ();
      node * () ;
      node * () = ;
       (, format_info) ;

      // protected member functions
       (node *, node *);
       (node *);
       (element *);
       (node *);
       (node *);
    };

## Description

Node is the abstract base class for all data contained in zeep XML documents. The DOM tree consists of nodes that are linked to each other, each node can have a parent and siblings pointed to by the next and previous members. All nodes in a DOM tree share a common root node.

Nodes can have a name, and the XPath specification requires that a node can have a so-called expanded-name. This name consists of a local-name and a namespace which is a URI. And we can have a QName which is a concatenation of a prefix (that points to a namespace URI) and a local-name separated by a colon.

To reduce storage requirements, names are stored in nodes as qnames, if at all. the convenience functions name() and prefix() parse the qname(). ns() returns the namespace URI for the node, if it can be resolved.

Nodes inherit the namespace of their parent unless they override it which means resolving prefixes and namespaces is done hierarchically

Nodes are stored in a node_list, a generic list class that resembles std::list

### `node` public construct/copy/destruct

1.     () = ;

2.     (node & n) = ;

3.     (node && n) = ;

4.     node & (node & n) = ;

5.     node & (node && n) = ;

6.     ~();

### `node` public member functions

1.      () ;

   content of a xml:lang attribute of this element, or its nearest ancestor

2.      () ;

   Nodes can have a name, and the XPath specification requires that a node can have a so-called expanded-name. This name consists of a local-name and a namespace which is a URI. And we can have a QName which is a concatenation of a prefix (that points to a namespace URI) and a local-name separated by a colon.

   To reduce storage requirements, names are stored in nodes as qnames, if at all.

3.      ();

4.      ( prefix,  name);

   set the qname with two parameters, if prefix is empty the qname will be simply name otherwise the name will be `prefix:name`

   Parameters:

   `name` | The actual name to use
   `prefix` | The namespace prefix to use

5.      () ;

   The name for the node as parsed from the qname.

6.      () ;

   The prefix for the node as parsed from the qname.

7.      () ;

   Returns the namespace URI for the node, if it can be resolved.

8.      ( prefix) ;

   Return the namespace URI for a prefix.

9.     ( uri) ;

   Return the prefix for a namespace URI.

10.     ( tag,  uri) ;

    Prefix the tag with the namespace prefix for uri.

11.      () ;

    return all content concatenated, including that of children.

12.      ( value) = ;

    Set text, what really happens depends on the type of the subclass implementing this method.

13.     element * ();

    The root node for this node.

14.     element * () ;

    The root node for this node.

15.     element * ();

    The parent node for this node.

16.     element * () ;

    The parent node for this node.

17.     node * ();

    The next sibling.

18.     node * () ;

    The next sibling.

19.     node * ();

    The previous sibling.

20.     node * () ;

    The previous sibling.

21.      (node * n) ;

    Compare the node with n.

22.      ();

    debug routine

23.     node * () ;

    return an exact copy of this node, including all data in sub nodes

24.     node * () = ;

    return a copy of this node, including all data in sub nodes, but in contrast with clone the data is moved from this node to the cloned node. This node will be empty afterwards.

25.      ( os, format_info fmt) ;

    low level routine for writing out XML

    This method is usually called by operator<<(std::ostream&, zeep::xml::document&)

### `node` protected member functions

1.      (node * n, node * before);

2.      (node * n);

3.      (element * p);

4.      (node * n);

5.      (node * n);