![]() |
zeep::xml::document
// In header: <zeep/xml/document.hpp> class document : public { public: // member classes/structs/unions struct notation { // public data members m_name; m_sysid; m_pubid; }; // construct/copy/destruct (); (document &); (document &&); (); (); (, ); document & (document &); document & (document &&); ~(); // public member functions () ; (); () ; (); () ; (); () ; (); () ; (); () ; (); () ; (); () ; (); () ; (); doc_type () ; (, , ); (doc_type &); () ; (); () ; (); () ; template<typename T> (, ); template<typename T> (, ); (document &) ; (document &) ; (); template<typename Callback> (); () ; (); () ; (); element * (); element * () ; node * (); node * () ; // friend functions (, document &); (, document &); // protected member functions (const_iterator, node *); (, , ); (, , ); (, ); (); (, ); (); (); (); (, ); (); (, , ); (, , ); (, , ); (); (, format_info) ; };
document
public
construct/copy/destruct();Constructor for an empty document.
(document & doc);Copy constructor.
(document && other);Move constructor.
( s);Constructor that will parse the XML passed in argument using default settings s.
( is);Constructor that will parse the XML passed in argument using default settings is.
( is, base_dir);Constructor that will parse the XML passed in argument is. This constructor will also validate the input using DTD's found in base_dir.
document & (document & doc);Copy operator=.
document & (document && other);Move operator=.
~();
document
public member functions() ;
options for parsing validating uses a DTD if it is defined
( validate);
() ;validating_ns: when validating take the NS 1.0 specification into account
( validate);
() ;
preserve cdata, preserves CDATA sections instead of converting them into text nodes.
( p);if p is true, the CDATA sections will be preserved when parsing XML, if p is false, the content of the CDATA will be treated as text
() ;collapse means replacing e.g.
<foo></foo>
with <foo/>
( c);if c is true, empty tags will be replaced, i.e. write
<foo/>
instead of <foo></foo>
() ;collapse 'empty elements' according to HTML rules
( f);if c is true, 'empty elements' will be collapsed according to HTML rules
() ;whether to write out comments
( s);if s is true, comments will not be written
() ;whether to escape white space
( e);if e is true, white space will be written as XML entities
() ;whether to escape double quotes
( e);if e is true, double quotes will be written as "
() ;whether to place a newline after a prolog
( w);if w is true, a newline will be written after the XML prolog
doc_type () ;Get the doctype as parsed.
( root, pubid, dtd);Set the doctype to write out.
(doc_type & doctype);Set the doctype to write out.
() ;whether to write a XML prolog
( w);if w is true, an XML prolog will be written
() ;whether to write a DOCTYPE
( f);if f is true a DOCTYPE will be written
() ;Check the doctype to see if this is supposed to be HTML5.
template<typename T> ( name, data);Serialization support.
Serialize data into a document containing name as root node
template<typename T> ( name, data);Serialization support.
Deserialize root node with name name into data.
(document & doc) ;Compare two xml documents.
(document & doc) ;
( path);
If you want to validate the document using DTD files stored on disk, you can specifiy this directory prior to reading the document.
template<typename Callback> ( cb);
If you want to be able to load external documents other than trying to read them from disk you can set a callback here.
() ;The text encoding as detected in the input.
( enc);The text encoding to use for output.
() ;XML version, should be either 1.0 or 1.1.
( v);XML version, should be either 1.0 or 1.1.
element * ();The root node for this node.
element * () ;The root node for this node.
node * ();
node * () ;
document
protected member functions(const_iterator pos, node * n);
( encoding, standalone, version);
( name, uri, atts);
( name, uri);
( data);
( target, data);
( comment);
();
();
( prefix, uri);
( prefix);
( root, publicId, uri);
( name, sysid, pubid);
( base, pubid, sysid);
( data);
( os, format_info fmt) ;low level routine for writing out XML
This method is usually called by operator<<(std::ostream&, zeep::xml::document&)