libUPnP 1.14.19
ixml.h
Go to the documentation of this file.
1/**************************************************************************
2 *
3 * Copyright (c) 2000-2003 Intel Corporation
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are met:
8 *
9 * - Redistributions of source code must retain the above copyright notice,
10 * this list of conditions and the following disclaimer.
11 * - Redistributions in binary form must reproduce the above copyright notice,
12 * this list of conditions and the following disclaimer in the documentation
13 * and/or other materials provided with the distribution.
14 * - Neither name of Intel Corporation nor the names of its contributors
15 * may be used to endorse or promote products derived from this software
16 * without specific prior written permission.
17 *
18 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
21 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR
22 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
23 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
24 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
25 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
26 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
27 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 *
30 **************************************************************************/
31
32#ifndef IXML_H
33#define IXML_H
34
43#include "UpnpGlobal.h" /* For UPNP_EXPORT_SPEC */
44
48#define DOMString char *
49/*typedef char *DOMString;*/
50
69typedef enum
70{
71 eINVALID_NODE = 0,
72 eELEMENT_NODE = 1,
73 eATTRIBUTE_NODE = 2,
74 eTEXT_NODE = 3,
75 eCDATA_SECTION_NODE = 4,
76 eENTITY_REFERENCE_NODE = 5,
77 eENTITY_NODE = 6,
78 ePROCESSING_INSTRUCTION_NODE = 7,
79 eCOMMENT_NODE = 8,
80 eDOCUMENT_NODE = 9,
81 eDOCUMENT_TYPE_NODE = 10,
82 eDOCUMENT_FRAGMENT_NODE = 11,
83 eNOTATION_NODE = 12
85
89typedef enum
90{
91 IXML_SUCCESS = 0,
92
93 IXML_INDEX_SIZE_ERR = 1,
94 IXML_DOMSTRING_SIZE_ERR = 2,
95 IXML_HIERARCHY_REQUEST_ERR = 3,
96 IXML_WRONG_DOCUMENT_ERR = 4,
97 IXML_INVALID_CHARACTER_ERR = 5,
98 IXML_NO_DATA_ALLOWED_ERR = 6,
99 IXML_NO_MODIFICATION_ALLOWED_ERR = 7,
100 IXML_NOT_FOUND_ERR = 8,
101 IXML_NOT_SUPPORTED_ERR = 9,
102 IXML_INUSE_ATTRIBUTE_ERR = 10,
103 IXML_INVALID_STATE_ERR = 11,
104 IXML_SYNTAX_ERR = 12,
105 IXML_INVALID_MODIFICATION_ERR = 13,
106 IXML_NAMESPACE_ERR = 14,
107 IXML_INVALID_ACCESS_ERR = 15,
108
109 IXML_NO_SUCH_FILE = 101,
110 IXML_INSUFFICIENT_MEMORY = 102,
111 IXML_FILE_DONE = 104,
112 IXML_INVALID_PARAMETER = 105,
113 IXML_FAILED = 106,
114 IXML_INVALID_ITEM_NUMBER = 107
116
117#define DOCUMENTNODENAME "#document"
118#define TEXTNODENAME "#text"
119#define CDATANODENAME "#cdata-section"
120
121typedef struct _IXML_Document *Docptr;
122
123typedef struct _IXML_Node *Nodeptr;
124
125#ifdef IXML_HAVE_SCRIPTSUPPORT
129typedef void (*IXML_BeforeFreeNode_t)(Nodeptr obj);
130#endif
131
135typedef struct _IXML_Node
136{
137 DOMString nodeName;
138 DOMString nodeValue;
139 IXML_NODE_TYPE nodeType;
140 DOMString namespaceURI;
141 DOMString prefix;
142 DOMString localName;
143 int readOnly;
144
145 Nodeptr parentNode;
146 Nodeptr firstChild;
147 Nodeptr prevSibling;
148 Nodeptr nextSibling;
149 Nodeptr firstAttr;
150 Docptr ownerDocument;
151#ifdef IXML_HAVE_SCRIPTSUPPORT
152 void *ctag; /* custom tag */
153#endif
155
159typedef struct _IXML_Document
160{
161 IXML_Node n;
163
171
175typedef struct _IXML_Element
176{
177 IXML_Node n;
178 DOMString tagName;
180
184typedef struct _IXML_ATTR
185{
186 IXML_Node n;
187 int specified;
188 IXML_Element *ownerElement;
190
194typedef struct _IXML_Text
195{
196 IXML_Node n;
198
202typedef struct _IXML_NodeList
203{
204 IXML_Node *nodeItem;
205 struct _IXML_NodeList *next;
207
211typedef struct _IXML_NamedNodeMap
212{
213 IXML_Node *nodeItem;
214 struct _IXML_NamedNodeMap *next;
216
217/* @} DOM Interfaces */
218
219#ifdef __cplusplus
220extern "C" {
221#endif
222
247 IXML_Node *nodeptr);
248
259 IXML_Node *nodeptr);
260
275 IXML_Node *nodeptr,
277 const char *newNodeValue);
278
287 IXML_Node *nodeptr);
288
297 IXML_Node *nodeptr);
298
310 IXML_Node *nodeptr);
311
320 IXML_Node *nodeptr);
321
330 IXML_Node *nodeptr);
331
340 IXML_Node *nodeptr);
341
350 IXML_Node *nodeptr);
351
360 IXML_Node *nodeptr);
361
374 IXML_Node *nodeptr);
375
387 IXML_Node *nodeptr);
388
401 IXML_Node *nodeptr);
402
416 IXML_Node *nodeptr);
417
446 IXML_Node *nodeptr,
448 IXML_Node *newChild,
451 IXML_Node *refChild);
452
478 IXML_Node *nodeptr,
480 IXML_Node *newChild,
482 IXML_Node *oldChild,
485 IXML_Node **returnNode);
486
505 IXML_Node *nodeptr,
507 IXML_Node *oldChild,
510 IXML_Node **returnNode);
511
531 IXML_Node *nodeptr,
533 IXML_Node *newChild);
534
542 IXML_Node *nodeptr);
543
557 IXML_Node *nodeptr,
560 int deep);
561
571 IXML_Node *nodeptr);
572
581 IXML_Node *nodeptr);
582
583#ifdef IXML_HAVE_SCRIPTSUPPORT
587UPNP_EXPORT_SPEC void ixmlNode_setCTag(
589 IXML_Node *nodeptr,
591 void *ctag);
592
596UPNP_EXPORT_SPEC void *ixmlNode_getCTag(
598 IXML_Node *nodeptr);
599#endif
600/* @} Interface Node */
601
620 IXML_Attr *attrNode);
621
622/* @} Interface Attr */
623
643 IXML_CDATASection *nodeptr);
644
650 IXML_CDATASection *nodeptr);
651
652/* @} Interface CDATASection */
653
672 IXML_Document *nodeptr);
673
689 IXML_Document **doc);
690
698
719 IXML_Document *doc,
721 const DOMString tagName,
724 IXML_Element **rtElement);
725
739 IXML_Document *doc,
741 const DOMString tagName);
742
759 IXML_Document *doc,
762 const DOMString data,
764 IXML_Node **textNode);
765
773 IXML_Document *doc,
776 const DOMString data);
777
794 IXML_Document *doc,
796 const DOMString data,
798 IXML_CDATASection **cdNode);
799
807 IXML_Document *doc,
809 const DOMString data);
810
822 IXML_Document *doc,
824 const DOMString name);
825
842 IXML_Document *doc,
844 const DOMString name,
846 IXML_Attr **attrNode);
847
858 IXML_Document *doc,
860 const DOMString tagName);
861
862/*
863 * introduced in DOM level 2
864 */
865
883 IXML_Document *doc,
885 const DOMString namespaceURI,
887 const DOMString qualifiedName,
890 IXML_Element **rtElement);
891
902 IXML_Document *doc,
904 const DOMString namespaceURI,
906 const DOMString qualifiedName);
907
925 IXML_Document *doc,
927 const DOMString namespaceURI,
929 const DOMString qualifiedName,
932 IXML_Attr **attrNode);
933
944 IXML_Document *doc,
946 const DOMString namespaceURI,
948 const DOMString qualifiedName);
949
963 IXML_Document *doc,
966 const DOMString namespaceURI,
969 const DOMString localName);
970
978 IXML_Document *doc,
980 const DOMString tagName);
981
991 IXML_Document *doc);
992
1025 IXML_Document *doc,
1027 IXML_Node *importNode,
1030 int deep,
1032 IXML_Node **rtNode);
1033
1034/* @} Interface Document */
1035
1053 IXML_Element *element);
1054
1062 IXML_Element *element);
1063
1072 IXML_Element *element,
1074 const DOMString name);
1075
1094 IXML_Element *element,
1096 const DOMString name,
1099 const DOMString value);
1100
1111 IXML_Element *element,
1113 const DOMString name);
1114
1125 IXML_Element *element,
1127 const DOMString name);
1128
1148 IXML_Element *element,
1150 IXML_Attr *newAttr,
1153 IXML_Attr **rtAttr);
1154
1167 IXML_Element *element,
1169 IXML_Attr *oldAttr,
1172 IXML_Attr **rtAttr);
1173
1183 IXML_Element *element,
1185 const DOMString tagName);
1186
1187/*
1188 * Introduced in DOM 2
1189 */
1190
1199 IXML_Element *element,
1201 const DOMString namespaceURI,
1203 const DOMString localname);
1204
1229 IXML_Element *element,
1231 const DOMString namespaceURI,
1233 const DOMString qualifiedName,
1235 const DOMString value);
1236
1250 IXML_Element *element,
1252 const DOMString namespaceURI,
1254 const DOMString localName);
1255
1264 IXML_Element *element,
1266 const DOMString namespaceURI,
1268 const DOMString localName);
1269
1292 IXML_Element *element,
1294 IXML_Attr *newAttr,
1296 IXML_Attr **rcAttr);
1297
1307 IXML_Element *element,
1311 const DOMString namespaceURI,
1314 const DOMString localName);
1315
1325 IXML_Element *element,
1327 const DOMString name);
1328
1338 IXML_Element *element,
1340 const DOMString namespaceURI,
1342 const DOMString localName);
1343
1349 IXML_Element *element);
1350
1351/* @} Interface Element */
1352
1371 IXML_NamedNodeMap *nnMap);
1372
1381 IXML_NamedNodeMap *nnMap,
1383 const DOMString name);
1384
1394 IXML_NamedNodeMap *nnMap,
1396 IXML_Node *arg);
1397
1405 IXML_NamedNodeMap *nnMap,
1407 const DOMString name);
1408
1418 IXML_NamedNodeMap *nnMap,
1420 unsigned long index);
1421
1422/*
1423 * Introduced in DOM level 2
1424 */
1425
1434 IXML_NamedNodeMap *nnMap,
1436 const DOMString *namespaceURI,
1438 const DOMString localName);
1439
1449 IXML_NamedNodeMap *nnMap,
1451 IXML_Node *arg);
1452
1461 IXML_NamedNodeMap *nnMap,
1463 const DOMString namespaceURI,
1465 const DOMString localName);
1466
1473 IXML_NamedNodeMap *nnMap);
1474
1475/* @} Interface NodeMap */
1476
1496 IXML_NodeList *nList,
1498 unsigned long index);
1499
1508 IXML_NodeList *nList);
1509
1518 IXML_NodeList *nList);
1519
1520/* @} Interface NodeList */
1521
1556 IXML_Document *doc);
1557
1577 IXML_Node *doc);
1578
1599 IXML_Document *doc);
1600
1617 IXML_Node *doc);
1618
1631 char errorChar);
1632
1633#ifdef IXML_HAVE_SCRIPTSUPPORT
1637UPNP_EXPORT_SPEC void ixmlSetBeforeFree(
1643 IXML_BeforeFreeNode_t hndlr);
1644#endif
1645
1655 const char *buffer);
1656
1675 const char *buffer,
1678 IXML_Document **doc);
1679
1687 const char *xmlFile);
1688
1705 const char *xmlFile,
1708 IXML_Document **doc);
1709
1718 const DOMString src);
1719
1725 DOMString buf);
1726
1727/* @} IXML API */
1728
1729#ifdef __cplusplus
1730}
1731#endif
1732
1733/* @} XMLAPI XML API */
1734
1735#endif /* IXML_H */
Defines constants that for some reason are not defined on some systems.
#define UPNP_EXPORT_SPEC
Export functions on WIN32 DLLs.
Definition UpnpGlobal.h:98
UPNP_EXPORT_SPEC const char * ixmlNode_getNodeValue(IXML_Node *nodeptr)
Returns the value of the Node as a string.
Definition node.c:310
UPNP_EXPORT_SPEC const char * ixmlNode_getNodeName(IXML_Node *nodeptr)
Returns the name of the Node, depending on what type of Node it is, in a read-only string.
Definition node.c:186
UPNP_EXPORT_SPEC IXML_Attr * ixmlDocument_createAttribute(IXML_Document *doc, const char *name)
Creates a new Attr node with the given name.
UPNP_EXPORT_SPEC void ixmlCDATASection_init(IXML_CDATASection *nodeptr)
Initializes a CDATASection node.
Definition node.c:52
UPNP_EXPORT_SPEC int ixmlElement_removeAttribute(IXML_Element *element, const char *name)
Removes an attribute value by name. The attribute node is not removed.
struct _IXML_Node IXML_Node
Data structure common to all types of nodes.
UPNP_EXPORT_SPEC int ixmlNode_insertBefore(IXML_Node *nodeptr, IXML_Node *newChild, IXML_Node *refChild)
Inserts a new child Node before the existing child Node.
Definition node.c:536
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_getNamedItem(IXML_NamedNodeMap *nnMap, const char *name)
Retrieves a Node from the NamedNodeMap by name.
UPNP_EXPORT_SPEC int ixmlNode_hasAttributes(IXML_Node *nodeptr)
Queries whether this Node has attributes.
Definition node.c:1227
UPNP_EXPORT_SPEC IXML_Node * ixmlNode_cloneNode(IXML_Node *nodeptr, int deep)
Clones a Node.
Definition node.c:1129
UPNP_EXPORT_SPEC const char * ixmlElement_getAttributeNS(IXML_Element *element, const char *namespaceURI, const char *localname)
Retrieves an attribute value using the local name and namespace URI.
struct _IXML_CDATASection IXML_CDATASection
Data structure representing a CDATA section node.
UPNP_EXPORT_SPEC IXML_Attr * ixmlElement_getAttributeNode(IXML_Element *element, const char *name)
Retrieves an attribute node by name. See ixmlElement_getAttributeNodeNS to retrieve an attribute node...
UPNP_EXPORT_SPEC void ixmlElement_init(IXML_Element *element)
Initializes a IXML_Element node.
Definition element.c:45
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_getNamedItemNS(IXML_NamedNodeMap *nnMap, const char **namespaceURI, const char *localName)
Retrieves a Node from a NamedNodeMap specified by namespace URI and local name.
UPNP_EXPORT_SPEC int ixmlNode_removeChild(IXML_Node *nodeptr, IXML_Node *oldChild, IXML_Node **returnNode)
Removes a child from the list of children of a Node.
Definition node.c:622
UPNP_EXPORT_SPEC void ixmlNode_free(IXML_Node *nodeptr)
Frees a Node and all Nodes in its subtree.
Definition node.c:126
UPNP_EXPORT_SPEC int ixmlDocument_createDocumentEx(IXML_Document **doc)
Creates a new empty Document node.
Definition document.c:169
UPNP_EXPORT_SPEC IXML_Element * ixmlDocument_getElementById(IXML_Document *doc, const char *tagName)
Returns the Element whose ID matches that given id.
UPNP_EXPORT_SPEC int ixmlNode_replaceChild(IXML_Node *nodeptr, IXML_Node *newChild, IXML_Node *oldChild, IXML_Node **returnNode)
Replaces an existing child Node with a new child Node in the list of children of a Node.
Definition node.c:584
struct _IXML_NodeList IXML_NodeList
Data structure representing a list of nodes.
UPNP_EXPORT_SPEC IXML_NodeList * ixmlNode_getChildNodes(IXML_Node *nodeptr)
Retrieves the list of children of a Node in a NodeList structure.
Definition node.c:1151
UPNP_EXPORT_SPEC void ixmlDocument_free(IXML_Document *doc)
Frees a Document object and all Nodes associated with it.
Definition document.c:51
UPNP_EXPORT_SPEC IXML_Node * ixmlNode_getParentNode(IXML_Node *nodeptr)
Retrieves the parent Node for a Node.
Definition node.c:351
UPNP_EXPORT_SPEC IXML_Node * ixmlDocument_createTextNode(IXML_Document *doc, const char *data)
Creates a new Text node with the given data.
UPNP_EXPORT_SPEC IXML_Document * ixmlLoadDocument(const char *xmlFile)
Parses an XML text file converting it into an IXML DOM representation.
Definition ixml.c:336
UPNP_EXPORT_SPEC const char * ixmlElement_getAttribute(IXML_Element *element, const char *name)
Retrieves an attribute of an Element by name.
UPNP_EXPORT_SPEC int ixmlParseBufferEx(const char *buffer, IXML_Document **doc)
Parses an XML text buffer converting it into an IXML DOM representation.
Definition ixml.c:418
#define DOMString
The type of DOM strings.
Definition ixml.h:48
UPNP_EXPORT_SPEC IXML_Document * ixmlDocument_createDocument(void)
Creates a new empty Document node.
Definition document.c:199
UPNP_EXPORT_SPEC char * ixmlNodetoString(IXML_Node *doc)
Renders a Node and all sub-elements into an XML text representation. The caller is required to free t...
Definition ixml.c:394
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_item(IXML_NamedNodeMap *nnMap, unsigned long index)
Retrieves the indexth item in the map. If index is greater than or equal to the number of nodes in th...
Definition namedNodeMap.c:96
struct _IXML_Document IXML_Document
Data structure representing the DOM Document.
UPNP_EXPORT_SPEC IXML_Attr * ixmlDocument_createAttributeNS(IXML_Document *doc, const char *namespaceURI, const char *qualifiedName)
Creates a new Attribute node with the given qualified name and namespace URI.
UPNP_EXPORT_SPEC void ixmlNamedNodeMap_free(IXML_NamedNodeMap *nnMap)
Frees a NamedNodeMap.
Definition namedNodeMap.c:134
UPNP_EXPORT_SPEC int ixmlNode_hasChildNodes(IXML_Node *nodeptr)
Queries whether or not a Node has children.
Definition node.c:1218
UPNP_EXPORT_SPEC const char * ixmlNode_getLocalName(IXML_Node *nodeptr)
Retrieves the local name of a Node, if present.
Definition node.c:195
UPNP_EXPORT_SPEC const char * ixmlElement_getTagName(IXML_Element *element)
Returns the name of the tag as a constant string.
Definition element.c:52
UPNP_EXPORT_SPEC IXML_CDATASection * ixmlDocument_createCDATASection(IXML_Document *doc, const char *data)
Creates a new CDATASection node with given data.
UPNP_EXPORT_SPEC char * ixmlPrintDocument(IXML_Document *doc)
Renders a Node and all sub-elements into an XML document representation.
Definition ixml.c:345
UPNP_EXPORT_SPEC int ixmlElement_setAttribute(IXML_Element *element, const char *name, const char *value)
Adds a new attribute to an Element.
UPNP_EXPORT_SPEC IXML_Node * ixmlNode_getFirstChild(IXML_Node *nodeptr)
Retrieves the first child Node of a Node.
Definition node.c:360
IXML_ERRORCODE
Error codes returned by the XML API, see the DOM spec.
Definition ixml.h:90
UPNP_EXPORT_SPEC int ixmlElement_removeAttributeNode(IXML_Element *element, IXML_Attr *oldAttr, IXML_Attr **rtAttr)
Removes the specified attribute node from an Element.
Definition element.c:315
struct _IXML_ATTR IXML_Attr
Data structure representing an Attribute node.
UPNP_EXPORT_SPEC void ixmlFreeDOMString(char *buf)
Frees a DOMString.
UPNP_EXPORT_SPEC int ixmlElement_setAttributeNode(IXML_Element *element, IXML_Attr *newAttr, IXML_Attr **rtAttr)
Adds a new attribute node to an Element.
Definition element.c:219
UPNP_EXPORT_SPEC int ixmlDocument_createTextNodeEx(IXML_Document *doc, const char *data, IXML_Node **textNode)
Creates a new Text node with the given data.
UPNP_EXPORT_SPEC int ixmlDocument_createElementNSEx(IXML_Document *doc, const char *namespaceURI, const char *qualifiedName, IXML_Element **rtElement)
Creates a new Element node in the given qualified name and namespace URI.
UPNP_EXPORT_SPEC int ixmlElement_hasAttributeNS(IXML_Element *element, const char *namespaceURI, const char *localName)
Queries whether the Element has an attribute with the given local name and namespace URI or has a def...
UPNP_EXPORT_SPEC int ixmlElement_hasAttribute(IXML_Element *element, const char *name)
Queries whether the Element has an attribute with the given name or a default value.
UPNP_EXPORT_SPEC IXML_Document * ixmlParseBuffer(const char *buffer)
Parses an XML text buffer converting it into an IXML DOM representation.
Definition ixml.c:431
UPNP_EXPORT_SPEC IXML_Node * ixmlNode_getPreviousSibling(IXML_Node *nodeptr)
Retrieves the sibling Node immediately preceding this Node.
Definition node.c:387
UPNP_EXPORT_SPEC int ixmlLoadDocumentEx(const char *xmlFile, IXML_Document **doc)
Parses an XML text file converting it into an IXML DOM representation.
Definition ixml.c:327
UPNP_EXPORT_SPEC unsigned long ixmlNamedNodeMap_getLength(IXML_NamedNodeMap *nnMap)
Returns the number of items contained in this NamedNodeMap.
Definition namedNodeMap.c:119
IXML_NODE_TYPE
The type of the DOM node.
Definition ixml.h:70
UPNP_EXPORT_SPEC void ixmlCDATASection_free(IXML_CDATASection *nodeptr)
Frees a CDATASection node.
Definition node.c:57
UPNP_EXPORT_SPEC char * ixmlDocumenttoString(IXML_Document *doc)
Renders a Node and all sub-elements into an XML document representation.
Definition ixml.c:377
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_removeNamedItemNS(IXML_NamedNodeMap *nnMap, const char *namespaceURI, const char *localName)
Removes a Node from a NamedNodeMap specified by namespace URI and local name.
UPNP_EXPORT_SPEC void ixmlElement_free(IXML_Element *element)
Frees the given Element and any subtree of the Element.
Definition element.c:684
struct _IXML_NamedNodeMap IXML_NamedNodeMap
Data structure representing a list of named nodes.
struct _IXML_Element IXML_Element
Data structure representing an Element node.
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_setNamedItemNS(IXML_NamedNodeMap *nnMap, IXML_Node *arg)
Adds a new Node to the NamedNodeMap using the Node local name and namespace URI attributes.
UPNP_EXPORT_SPEC int ixmlNode_setNodeValue(IXML_Node *nodeptr, const char *newNodeValue)
Assigns a new value to a Node.
Definition node.c:319
struct _IXML_Text IXML_Text
Data structure representing a Text node.
UPNP_EXPORT_SPEC int ixmlNode_appendChild(IXML_Node *nodeptr, IXML_Node *newChild)
Appends a child Node to the list of children of a Node.
Definition node.c:646
UPNP_EXPORT_SPEC int ixmlDocument_createAttributeEx(IXML_Document *doc, const char *name, IXML_Attr **attrNode)
Creates a new Attr node with the given name.
UPNP_EXPORT_SPEC const char * ixmlNode_getPrefix(IXML_Node *nodeptr)
Retrieves the namespace prefix, if present.
Definition node.c:299
UPNP_EXPORT_SPEC IXML_Document * ixmlNode_getOwnerDocument(IXML_Node *nodeptr)
Retrieves the document object associated with this Node.
Definition node.c:405
UPNP_EXPORT_SPEC IXML_NodeList * ixmlElement_getElementsByTagName(IXML_Element *element, const char *tagName)
Returns a NodeList of all descendant Elements with a given tag name, in the order in which they are e...
UPNP_EXPORT_SPEC void ixmlRelaxParser(char errorChar)
Makes the XML parser more tolerant to malformed text.
Definition ixml.c:409
UPNP_EXPORT_SPEC IXML_NodeList * ixmlElement_getElementsByTagNameNS(IXML_Element *element, const char *namespaceURI, const char *localName)
Returns a NodeList of all descendant Elements with a given local name and namespace in the order in w...
UPNP_EXPORT_SPEC unsigned long ixmlNodeList_length(IXML_NodeList *nList)
Returns the number of Nodes in a NodeList.
Definition nodeList.c:118
UPNP_EXPORT_SPEC int ixmlElement_setAttributeNS(IXML_Element *element, const char *namespaceURI, const char *qualifiedName, const char *value)
Adds a new attribute to an Element using the local name and namespace URI.
UPNP_EXPORT_SPEC void ixmlAttr_free(IXML_Attr *attrNode)
Frees an Attr node.
Definition attr.c:44
UPNP_EXPORT_SPEC int ixmlDocument_importNode(IXML_Document *doc, IXML_Node *importNode, int deep, IXML_Node **rtNode)
Imports a Node from another Document into this Document.
Definition document.c:79
UPNP_EXPORT_SPEC IXML_Attr * ixmlElement_getAttributeNodeNS(IXML_Element *element, const char *namespaceURI, const char *localName)
Retrieves an Attr node by local name and namespace URI.
UPNP_EXPORT_SPEC const char * ixmlNode_getNamespaceURI(IXML_Node *nodeptr)
Retrieves the namespace URI for a Node as a DOMString.
Definition node.c:288
UPNP_EXPORT_SPEC int ixmlElement_removeAttributeNS(IXML_Element *element, const char *namespaceURI, const char *localName)
Removes an attribute using the namespace URI and local name.
UPNP_EXPORT_SPEC void ixmlDocument_init(IXML_Document *nodeptr)
Initializes a Document node.
Definition document.c:46
UPNP_EXPORT_SPEC int ixmlDocument_createAttributeNSEx(IXML_Document *doc, const char *namespaceURI, const char *qualifiedName, IXML_Attr **attrNode)
Creates a new Attr node with the given qualified name and namespace URI.
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_removeNamedItem(IXML_NamedNodeMap *nnMap, const char *name)
Removes a Node from a NamedNodeMap specified by name.
UPNP_EXPORT_SPEC unsigned short ixmlNode_getNodeType(IXML_Node *nodeptr)
Retrieves the type of a Node. Note that not all possible return values are actually implemented.
Definition node.c:342
UPNP_EXPORT_SPEC IXML_Node * ixmlNode_getNextSibling(IXML_Node *nodeptr)
Retrieves the sibling Node immediately following this Node.
Definition node.c:396
UPNP_EXPORT_SPEC IXML_NodeList * ixmlDocument_getElementsByTagName(IXML_Document *doc, const char *tagName)
Returns a NodeList of all Elements that match the given tag name in the order in which they were enco...
UPNP_EXPORT_SPEC void ixmlNodeList_free(IXML_NodeList *nList)
Frees a NodeList object.
Definition nodeList.c:132
UPNP_EXPORT_SPEC IXML_Node * ixmlNodeList_item(IXML_NodeList *nList, unsigned long index)
Retrieves a Node from a NodeList specified by a numerical index.
Definition nodeList.c:49
UPNP_EXPORT_SPEC IXML_Element * ixmlDocument_createElement(IXML_Document *doc, const char *tagName)
Creates a new Element node with the given tag name.
UPNP_EXPORT_SPEC IXML_Element * ixmlDocument_createElementNS(IXML_Document *doc, const char *namespaceURI, const char *qualifiedName)
Creates a new Element node in the given qualified name and namespace URI.
UPNP_EXPORT_SPEC IXML_Node * ixmlNode_getLastChild(IXML_Node *nodeptr)
Retrieves the last child Node of a Node.
Definition node.c:369
UPNP_EXPORT_SPEC IXML_Node * ixmlNamedNodeMap_setNamedItem(IXML_NamedNodeMap *nnMap, IXML_Node *arg)
Adds a new Node to the NamedNodeMap using the Node name attribute.
UPNP_EXPORT_SPEC IXML_NamedNodeMap * ixmlNode_getAttributes(IXML_Node *nodeptr)
Retrieves the attributes of a Node, if it is an Element node, in a NamedNodeMap structure.
Definition node.c:1181
UPNP_EXPORT_SPEC int ixmlElement_setAttributeNodeNS(IXML_Element *element, IXML_Attr *newAttr, IXML_Attr **rcAttr)
Adds a new attribute node to the element node specified.
Definition element.c:549
UPNP_EXPORT_SPEC int ixmlDocument_createElementEx(IXML_Document *doc, const char *tagName, IXML_Element **rtElement)
Creates a new Element node with the given tag name.
UPNP_EXPORT_SPEC char * ixmlCloneDOMString(const char *src)
Clones an existing DOMString.
UPNP_EXPORT_SPEC char * ixmlPrintNode(IXML_Node *doc)
Renders a Node and all sub-elements into an XML text representation.
Definition ixml.c:362
UPNP_EXPORT_SPEC int ixmlDocument_createCDATASectionEx(IXML_Document *doc, const char *data, IXML_CDATASection **cdNode)
Creates a new CDATASection node with given data.
UPNP_EXPORT_SPEC IXML_NodeList * ixmlDocument_getElementsByTagNameNS(IXML_Document *doc, const char *namespaceURI, const char *localName)
Returns a NodeList of Elements that match the given local name and namespace URI in the order they ar...
Data structure representing an Attribute node.
Definition ixml.h:185
Data structure representing a CDATA section node.
Definition ixml.h:168
Data structure representing the DOM Document.
Definition ixml.h:160
Data structure representing an Element node.
Definition ixml.h:176
Data structure representing a list of named nodes.
Definition ixml.h:212
Data structure representing a list of nodes.
Definition ixml.h:203
Data structure common to all types of nodes.
Definition ixml.h:136
Data structure representing a Text node.
Definition ixml.h:195