Main Page   Modules   Compound List   File List   Compound Members   File Members   Related Pages  

wbxml_tree.h File Reference

WBXML Tree. More...

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Compounds

struct  WBXMLTree_s
 WBXML Tree structure. More...

struct  WBXMLTreeAttribute_s
 WBXML Tree Attribute structure. More...

struct  WBXMLTreeClbCtx_s
struct  WBXMLTreeNode_s
 WBXML Tree Node structure. More...


Typedefs

typedef enum WBXMLTreeNodeType_e WBXMLTreeNodeType
 WBXML Tree Node Type.

typedef WBXMLTreeAttribute_s WBXMLTreeAttribute
 WBXML Tree Attribute structure.

typedef WBXMLTreeNode_s WBXMLTreeNode
 WBXML Tree Node structure.

typedef WBXMLTree_s WBXMLTree
 WBXML Tree structure.

typedef WBXMLTreeClbCtx_s WBXMLTreeClbCtx

Enumerations

enum  WBXMLTreeNodeType_e { WBXML_TREE_ELEMENT_NODE = 0, WBXML_TREE_TEXT_NODE, WBXML_TREE_PI_NODE, WBXML_TREE_TREE_NODE }
 WBXML Tree Node Type. More...


Functions

WBXMLError wbxml_tree_from_wbxml (WB_UTINY *wbxml, WB_ULONG wbxml_len, WBXMLLanguage lang, WBXMLTree **tree)
 Parse a WBXML document, using internal callbacks, and construct a WBXML Tree.

WBXMLError wbxml_tree_from_xml (WB_UTINY *xml, WBXMLTree **tree)
 Parse an XML document, using internal callbacks, and construct a WBXML Tree.

WBXMLTreeAttributewbxml_tree_attribute_create (void)
 Create a Tree Attribute structure.

void wbxml_tree_attribute_destroy (WBXMLTreeAttribute *attr)
 Destroy a Tree Attribute structure.

WBXMLTreeNodewbxml_tree_node_create (WBXMLTreeNodeType type)
 Create a Tree Node structure.

void wbxml_tree_node_destroy (WBXMLTreeNode *node)
 Destroy a Tree Node structure.

WBXMLTreewbxml_tree_create (void)
 Create a Tree structure.

void wbxml_tree_destroy (WBXMLTree *tree)
 Destroy a Tree structure.

WBXMLTreeNodewbxml_tree_get_element_node_from_name (WBXMLTreeNode *node, const char *name, WB_BOOL recurs)
 Get an Element Node, given the Element Name.


Detailed Description

WBXML Tree.

Author:
Aymerick Jéhanne <libwbxml@jehanne.org>
Date:
03/02/16

Definition in file wbxml_tree.h.


Function Documentation

WBXMLTreeAttribute* wbxml_tree_attribute_create void   
 

Create a Tree Attribute structure.

Returns:
The newly created Tree Attribute, or NULL if not enough memory

Definition at line 191 of file wbxml_tree.c.

References WBXMLTreeAttribute_s::attr, WBXMLTreeAttribute_s::next, NULL, and wbxml_malloc().

void wbxml_tree_attribute_destroy WBXMLTreeAttribute   attr
 

Destroy a Tree Attribute structure.

Parameters:
attr The Tree Attribute structure to destroy

Definition at line 205 of file wbxml_tree.c.

References WBXMLTreeAttribute_s::attr, WBXMLTreeAttribute_s::next, NULL, wbxml_attribute_destroy(), and wbxml_free().

Referenced by wbxml_tree_node_destroy().

WBXMLTree* wbxml_tree_create void   
 

Create a Tree structure.

Returns:
The newly created Tree, or NULL if not enough memory

Definition at line 261 of file wbxml_tree.c.

References WBXMLTree_s::lang, NULL, WBXMLTree_s::root, and wbxml_malloc().

Referenced by wbxml_tree_from_wbxml(), and wbxml_tree_from_xml().

void wbxml_tree_destroy WBXMLTree   tree
 

Destroy a Tree structure.

Parameters:
tree The Tree structure to destroy

Definition at line 275 of file wbxml_tree.c.

References WBXMLTreeNode_s::children, FALSE, WBXMLTreeNode_s::next, NULL, WBXMLTreeNode_s::parent, WBXMLTree_s::root, TRUE, WB_BOOL, wbxml_free(), and wbxml_tree_node_destroy().

Referenced by wbxml_conv_wbxml2xml(), wbxml_conv_xml2wbxml(), wbxml_tree_clb_wbxml_characters(), wbxml_tree_clb_xml_end_element(), wbxml_tree_from_wbxml(), wbxml_tree_from_xml(), and wbxml_tree_node_destroy().

WBXMLTreeNode* wbxml_tree_node_create WBXMLTreeNodeType    type
 

Create a Tree Node structure.

Parameters:
type Node type
Returns:
The newly created Tree Node, or NULL if not enough memory

Definition at line 223 of file wbxml_tree.c.

References WBXMLTreeNode_s::attrs, WBXMLTreeNode_s::children, WBXMLTreeNode_s::content, WBXMLTreeNode_s::name, WBXMLTreeNode_s::next, NULL, WBXMLTreeNode_s::parent, WBXMLTreeNode_s::prev, WBXMLTreeNode_s::tree, WBXMLTreeNode_s::type, wbxml_malloc(), and WBXMLTreeNodeType.

Referenced by wbxml_tree_clb_wbxml_characters(), wbxml_tree_clb_wbxml_start_element(), wbxml_tree_clb_xml_characters(), wbxml_tree_clb_xml_end_element(), and wbxml_tree_clb_xml_start_element().

void wbxml_tree_node_destroy WBXMLTreeNode   node
 

Destroy a Tree Node structure.

Parameters:
node The Tree Node structure to destroy

Definition at line 245 of file wbxml_tree.c.

References WBXMLTreeNode_s::attrs, WBXMLTreeNode_s::content, WBXMLTreeNode_s::name, NULL, WBXMLTreeNode_s::tree, wbxml_buffer_destroy(), wbxml_free(), wbxml_tag_destroy(), wbxml_tree_attribute_destroy(), and wbxml_tree_destroy().

Referenced by wbxml_tree_clb_wbxml_characters(), wbxml_tree_clb_wbxml_start_element(), wbxml_tree_clb_xml_characters(), wbxml_tree_clb_xml_start_element(), and wbxml_tree_destroy().


Generated on Mon Nov 24 20:09:46 2003 for WBXML Library by doxygen1.3-rc1