• Home
  • Raw
  • Download

Lines Matching refs:doc

62 xmlNewReconciliedNs(xmlDocPtr doc, xmlNodePtr tree, xmlNsPtr ns);
876 xmlNewDtd(xmlDocPtr doc, const xmlChar *name, in xmlNewDtd() argument
880 if ((doc != NULL) && (doc->extSubset != NULL)) { in xmlNewDtd()
884 /* !!! */ (char *) name, doc->name, in xmlNewDtd()
885 /* !!! */ (char *)doc->extSubset->name); in xmlNewDtd()
907 if (doc != NULL) in xmlNewDtd()
908 doc->extSubset = cur; in xmlNewDtd()
909 cur->doc = doc; in xmlNewDtd()
925 xmlGetIntSubset(const xmlDoc *doc) { in xmlGetIntSubset() argument
928 if (doc == NULL) in xmlGetIntSubset()
930 cur = doc->children; in xmlGetIntSubset()
936 return((xmlDtdPtr) doc->intSubset); in xmlGetIntSubset()
950 xmlCreateIntSubset(xmlDocPtr doc, const xmlChar *name, in xmlCreateIntSubset() argument
954 if ((doc != NULL) && (xmlGetIntSubset(doc) != NULL)) { in xmlCreateIntSubset()
959 doc->name); in xmlCreateIntSubset()
1005 if (doc != NULL) { in xmlCreateIntSubset()
1006 doc->intSubset = cur; in xmlCreateIntSubset()
1007 cur->parent = doc; in xmlCreateIntSubset()
1008 cur->doc = doc; in xmlCreateIntSubset()
1009 if (doc->children == NULL) { in xmlCreateIntSubset()
1010 doc->children = (xmlNodePtr) cur; in xmlCreateIntSubset()
1011 doc->last = (xmlNodePtr) cur; in xmlCreateIntSubset()
1013 if (doc->type == XML_HTML_DOCUMENT_NODE) { in xmlCreateIntSubset()
1016 prev = doc->children; in xmlCreateIntSubset()
1019 doc->children = (xmlNodePtr) cur; in xmlCreateIntSubset()
1023 next = doc->children; in xmlCreateIntSubset()
1027 cur->prev = doc->last; in xmlCreateIntSubset()
1030 doc->last = (xmlNodePtr) cur; in xmlCreateIntSubset()
1035 doc->children = (xmlNodePtr) cur; in xmlCreateIntSubset()
1110 if (cur->doc != NULL) dict = cur->doc->dict; in xmlFreeDtd()
1187 cur->doc = cur; in xmlNewDoc()
1275 xmlStringLenGetNodeList(const xmlDoc *doc, const xmlChar *value, int len) { in xmlStringLenGetNodeList() argument
1318 xmlTreeErr(XML_TREE_INVALID_HEX, (xmlNodePtr) doc, in xmlStringLenGetNodeList()
1342 xmlTreeErr(XML_TREE_INVALID_DEC, (xmlNodePtr) doc, in xmlStringLenGetNodeList()
1364 xmlTreeErr(XML_TREE_UNTERMINATED_ENTITY, (xmlNodePtr) doc, in xmlStringLenGetNodeList()
1373 ent = xmlGetDocEntity(doc, val); in xmlStringLenGetNodeList()
1385 node = xmlNewDocText(doc, NULL); in xmlStringLenGetNodeList()
1402 node = xmlNewReference(doc, val); in xmlStringLenGetNodeList()
1412 ent->children = xmlStringGetNodeList(doc, in xmlStringLenGetNodeList()
1457 node = xmlNewDocText(doc, NULL); in xmlStringLenGetNodeList()
1467 ret = xmlNewDocText(doc, BAD_CAST ""); in xmlStringLenGetNodeList()
1485 xmlStringGetNodeList(const xmlDoc *doc, const xmlChar *value) { in xmlStringGetNodeList() argument
1525 xmlTreeErr(XML_TREE_INVALID_HEX, (xmlNodePtr) doc, in xmlStringGetNodeList()
1543 xmlTreeErr(XML_TREE_INVALID_DEC, (xmlNodePtr) doc, in xmlStringGetNodeList()
1563 (xmlNodePtr) doc, (const char *) q); in xmlStringGetNodeList()
1571 ent = xmlGetDocEntity(doc, val); in xmlStringGetNodeList()
1583 node = xmlNewDocText(doc, NULL); in xmlStringGetNodeList()
1596 node = xmlNewReference(doc, val); in xmlStringGetNodeList()
1606 ent->children = xmlStringGetNodeList(doc, in xmlStringGetNodeList()
1649 node = xmlNewDocText(doc, NULL); in xmlStringGetNodeList()
1676 xmlNodeListGetString(xmlDocPtr doc, const xmlNode *list, int inLine) in xmlNodeListGetString() argument
1699 buffer = xmlEncodeAttributeEntities(doc, node->content); in xmlNodeListGetString()
1701 buffer = xmlEncodeEntitiesReentrant(doc, node->content); in xmlNodeListGetString()
1709 ent = xmlGetDocEntity(doc, node->name); in xmlNodeListGetString()
1720 buffer = xmlNodeListGetString(doc, ent->children, 1); in xmlNodeListGetString()
1766 xmlNodeListGetRawString(const xmlDoc *doc, const xmlNode *list, int inLine) in xmlNodeListGetRawString() argument
1783 buffer = xmlEncodeSpecialChars(doc, node->content); in xmlNodeListGetRawString()
1791 ent = xmlGetDocEntity(doc, node->name); in xmlNodeListGetRawString()
1803 xmlNodeListGetRawString(doc, ent->children, 1); in xmlNodeListGetRawString()
1842 xmlDocPtr doc = NULL; in xmlNewPropInternal() local
1846 ((node->doc == NULL) || in xmlNewPropInternal()
1847 (!(xmlDictOwns(node->doc->dict, name))))) in xmlNewPropInternal()
1858 ((node == NULL) || (node->doc == NULL) || in xmlNewPropInternal()
1859 (!(xmlDictOwns(node->doc->dict, name))))) in xmlNewPropInternal()
1869 doc = node->doc; in xmlNewPropInternal()
1870 cur->doc = doc; in xmlNewPropInternal()
1875 if ((doc != NULL) && (doc->dict != NULL)) in xmlNewPropInternal()
1876 cur->name = (xmlChar *) xmlDictLookup(doc->dict, name, -1); in xmlNewPropInternal()
1886 xmlTreeErr(XML_TREE_NOT_UTF8, (xmlNodePtr) doc, in xmlNewPropInternal()
1888 if (doc != NULL) in xmlNewPropInternal()
1889 doc->encoding = xmlStrdup(BAD_CAST "ISO-8859-1"); in xmlNewPropInternal()
1891 cur->children = xmlNewDocText(doc, value); in xmlNewPropInternal()
1919 (xmlIsID(node->doc, node, cur) == 1)) in xmlNewPropInternal()
1920 xmlAddID(NULL, node->doc, value, cur); in xmlNewPropInternal()
2013 xmlNewDocProp(xmlDocPtr doc, const xmlChar *name, const xmlChar *value) { in xmlNewDocProp() argument
2035 if ((doc != NULL) && (doc->dict != NULL)) in xmlNewDocProp()
2036 cur->name = xmlDictLookup(doc->dict, name, -1); in xmlNewDocProp()
2039 cur->doc = doc; in xmlNewDocProp()
2043 cur->children = xmlStringGetNodeList(doc, value); in xmlNewDocProp()
2088 if (cur->doc != NULL) dict = cur->doc->dict; in xmlFreeProp()
2094 if ((cur->doc != NULL) && (cur->atype == XML_ATTRIBUTE_ID)) { in xmlFreeProp()
2095 xmlRemoveID(cur->doc, cur); in xmlFreeProp()
2163 xmlNewDocPI(xmlDocPtr doc, const xmlChar *name, const xmlChar *content) { in xmlNewDocPI() argument
2185 if ((doc != NULL) && (doc->dict != NULL)) in xmlNewDocPI()
2186 cur->name = xmlDictLookup(doc->dict, name, -1); in xmlNewDocPI()
2192 cur->doc = doc; in xmlNewDocPI()
2315 xmlNewDocNode(xmlDocPtr doc, xmlNsPtr ns, in xmlNewDocNode() argument
2319 if ((doc != NULL) && (doc->dict != NULL)) in xmlNewDocNode()
2321 xmlDictLookup(doc->dict, name, -1)); in xmlNewDocNode()
2325 cur->doc = doc; in xmlNewDocNode()
2327 cur->children = xmlStringGetNodeList(doc, content); in xmlNewDocNode()
2352 xmlNewDocNodeEatName(xmlDocPtr doc, xmlNsPtr ns, in xmlNewDocNodeEatName() argument
2358 cur->doc = doc; in xmlNewDocNodeEatName()
2360 cur->children = xmlStringGetNodeList(doc, content); in xmlNewDocNodeEatName()
2365 if ((name != NULL) && (doc != NULL) && in xmlNewDocNodeEatName()
2366 (!(xmlDictOwns(doc->dict, name)))) in xmlNewDocNodeEatName()
2386 xmlNewDocRawNode(xmlDocPtr doc, xmlNsPtr ns, in xmlNewDocRawNode() argument
2390 cur = xmlNewDocNode(doc, ns, name, NULL); in xmlNewDocRawNode()
2392 cur->doc = doc; in xmlNewDocRawNode()
2394 cur->children = xmlNewDocText(doc, content); in xmlNewDocRawNode()
2409 xmlNewDocFragment(xmlDocPtr doc) { in xmlNewDocFragment() argument
2423 cur->doc = doc; in xmlNewDocFragment()
2509 cur = xmlNewDocRawNode(parent->doc, parent->ns, name, content); in xmlNewTextChild()
2511 cur = xmlNewDocRawNode(parent->doc, ns, name, content); in xmlNewTextChild()
2519 cur = xmlNewDocRawNode( parent->doc, ns, name, content); in xmlNewTextChild()
2530 cur->doc = parent->doc; in xmlNewTextChild()
2554 xmlNewCharRef(xmlDocPtr doc, const xmlChar *name) { in xmlNewCharRef() argument
2571 cur->doc = doc; in xmlNewCharRef()
2597 xmlNewReference(const xmlDoc *doc, const xmlChar *name) { in xmlNewReference() argument
2615 cur->doc = (xmlDoc *)doc; in xmlNewReference()
2627 ent = xmlGetDocEntity(doc, cur->name); in xmlNewReference()
2653 xmlNewDocText(const xmlDoc *doc, const xmlChar *content) { in xmlNewDocText() argument
2657 if (cur != NULL) cur->doc = (xmlDoc *)doc; in xmlNewDocText()
2705 xmlNewDocTextLen(xmlDocPtr doc, const xmlChar *content, int len) { in xmlNewDocTextLen() argument
2709 if (cur != NULL) cur->doc = doc; in xmlNewDocTextLen()
2755 xmlNewCDataBlock(xmlDocPtr doc, const xmlChar *content, int len) { in xmlNewCDataBlock() argument
2768 cur->doc = doc; in xmlNewCDataBlock()
2788 xmlNewDocComment(xmlDocPtr doc, const xmlChar *content) { in xmlNewDocComment() argument
2792 if (cur != NULL) cur->doc = doc; in xmlNewDocComment()
2804 xmlSetTreeDoc(xmlNodePtr tree, xmlDocPtr doc) { in xmlSetTreeDoc() argument
2809 if (tree->doc != doc) { in xmlSetTreeDoc()
2814 xmlRemoveID(tree->doc, prop); in xmlSetTreeDoc()
2817 prop->doc = doc; in xmlSetTreeDoc()
2818 xmlSetListDoc(prop->children, doc); in xmlSetTreeDoc()
2827 if (xmlIsID(doc, tree, prop)) { in xmlSetTreeDoc()
2828 xmlChar *idVal = xmlNodeListGetString(doc, prop->children, in xmlSetTreeDoc()
2830 xmlAddID(NULL, doc, idVal, prop); in xmlSetTreeDoc()
2838 xmlSetListDoc(tree->children, doc); in xmlSetTreeDoc()
2839 tree->doc = doc; in xmlSetTreeDoc()
2851 xmlSetListDoc(xmlNodePtr list, xmlDocPtr doc) { in xmlSetListDoc() argument
2858 if (cur->doc != doc) in xmlSetListDoc()
2859 xmlSetTreeDoc(cur, doc); in xmlSetListDoc()
2908 cur = xmlNewDocNode(parent->doc, parent->ns, name, content); in xmlNewChild()
2910 cur = xmlNewDocNode(parent->doc, ns, name, content); in xmlNewChild()
2918 cur = xmlNewDocNode( parent->doc, ns, name, content); in xmlNewChild()
2929 cur->doc = parent->doc; in xmlNewChild()
2972 if (prop->doc != cur->doc) { in xmlAddPropSibling()
2973 xmlSetTreeDoc(prop, cur->doc); in xmlAddPropSibling()
3057 if (elem->doc != cur->doc) { in xmlAddNextSibling()
3058 xmlSetTreeDoc(elem, cur->doc); in xmlAddNextSibling()
3135 if (elem->doc != cur->doc) { in xmlAddPrevSibling()
3136 xmlSetTreeDoc(elem, cur->doc); in xmlAddPrevSibling()
3215 if (elem->doc != cur->doc) { in xmlAddSibling()
3216 xmlSetTreeDoc(elem, cur->doc); in xmlAddSibling()
3259 if ((cur->doc != NULL) && (parent->doc != NULL) && in xmlAddChildList()
3260 (cur->doc != parent->doc)) { in xmlAddChildList()
3298 if (cur->doc != parent->doc) { in xmlAddChildList()
3299 xmlSetTreeDoc(cur, parent->doc); in xmlAddChildList()
3305 if (cur->doc != parent->doc) { in xmlAddChildList()
3306 xmlSetTreeDoc(cur, parent->doc); in xmlAddChildList()
3378 if (cur->doc != parent->doc) { in xmlAddChild()
3379 xmlSetTreeDoc(cur, parent->doc); in xmlAddChild()
3682 if (cur->doc != NULL) dict = cur->doc->dict; in xmlFreeNodeList()
3757 if (cur->doc != NULL) dict = cur->doc->dict; in xmlFreeNode()
3821 xmlDocPtr doc; in xmlUnlinkNode() local
3822 doc = cur->doc; in xmlUnlinkNode()
3823 if (doc != NULL) { in xmlUnlinkNode()
3824 if (doc->intSubset == (xmlDtdPtr) cur) in xmlUnlinkNode()
3825 doc->intSubset = NULL; in xmlUnlinkNode()
3826 if (doc->extSubset == (xmlDtdPtr) cur) in xmlUnlinkNode()
3827 doc->extSubset = NULL; in xmlUnlinkNode()
3831 xmlDocPtr doc; in xmlUnlinkNode() local
3832 doc = cur->doc; in xmlUnlinkNode()
3833 if (doc != NULL) { in xmlUnlinkNode()
3834 if (doc->intSubset != NULL) { in xmlUnlinkNode()
3835 if (xmlHashLookup(doc->intSubset->entities, cur->name) == cur) in xmlUnlinkNode()
3836 xmlHashRemoveEntry(doc->intSubset->entities, cur->name, in xmlUnlinkNode()
3838 if (xmlHashLookup(doc->intSubset->pentities, cur->name) == cur) in xmlUnlinkNode()
3839 xmlHashRemoveEntry(doc->intSubset->pentities, cur->name, in xmlUnlinkNode()
3842 if (doc->extSubset != NULL) { in xmlUnlinkNode()
3843 if (xmlHashLookup(doc->extSubset->entities, cur->name) == cur) in xmlUnlinkNode()
3844 xmlHashRemoveEntry(doc->extSubset->entities, cur->name, in xmlUnlinkNode()
3846 if (xmlHashLookup(doc->extSubset->pentities, cur->name) == cur) in xmlUnlinkNode()
3847 xmlHashRemoveEntry(doc->extSubset->pentities, cur->name, in xmlUnlinkNode()
3918 xmlSetTreeDoc(cur, old->doc); in xmlReplaceNode()
4003 xmlStaticCopyNodeList(xmlNodePtr node, xmlDocPtr doc, xmlNodePtr parent);
4006 xmlCopyPropInternal(xmlDocPtr doc, xmlNodePtr target, xmlAttrPtr cur) { in xmlCopyPropInternal() argument
4013 ret = xmlNewDocProp(target->doc, cur->name, NULL); in xmlCopyPropInternal()
4014 else if (doc != NULL) in xmlCopyPropInternal()
4015 ret = xmlNewDocProp(doc, cur->name, NULL); in xmlCopyPropInternal()
4017 ret = xmlNewDocProp(cur->parent->doc, cur->name, NULL); in xmlCopyPropInternal()
4019 ret = xmlNewDocProp(cur->children->doc, cur->name, NULL); in xmlCopyPropInternal()
4028 ns = xmlSearchNs(target->doc, target, cur->ns->prefix); in xmlCopyPropInternal()
4035 ns = xmlSearchNs(cur->doc, cur->parent, cur->ns->prefix); in xmlCopyPropInternal()
4044 if (root == (xmlNodePtr) target->doc) { in xmlCopyPropInternal()
4064 ret->ns = xmlNewReconciliedNs(target->doc, target, cur->ns); in xmlCopyPropInternal()
4074 ret->children = xmlStaticCopyNodeList(cur->children, ret->doc, (xmlNodePtr) ret); in xmlCopyPropInternal()
4088 (target->doc != NULL) && (cur->doc != NULL) && in xmlCopyPropInternal()
4089 (cur->doc->ids != NULL) && (cur->parent != NULL)) { in xmlCopyPropInternal()
4090 if (xmlIsID(cur->doc, cur->parent, cur)) { in xmlCopyPropInternal()
4093 id = xmlNodeListGetString(cur->doc, cur->children, 1); in xmlCopyPropInternal()
4095 xmlAddID(NULL, target->doc, id, ret); in xmlCopyPropInternal()
4169 xmlStaticCopyNode(xmlNodePtr node, xmlDocPtr doc, xmlNodePtr parent, in xmlStaticCopyNode() argument
4187 return((xmlNodePtr) xmlCopyPropInternal(doc, parent, (xmlAttrPtr) node)); in xmlStaticCopyNode()
4219 ret->doc = doc; in xmlStaticCopyNode()
4228 if ((doc != NULL) && (doc->dict != NULL)) in xmlStaticCopyNode()
4229 ret->name = xmlDictLookup(doc->dict, node->name, -1); in xmlStaticCopyNode()
4269 ns = xmlSearchNs(doc, ret, node->ns->prefix); in xmlStaticCopyNode()
4276 ns = xmlSearchNs(node->doc, node, node->ns->prefix); in xmlStaticCopyNode()
4283 ret->ns = xmlNewReconciliedNs(doc, ret, node->ns); in xmlStaticCopyNode()
4296 if ((doc == NULL) || (node->doc != doc)) { in xmlStaticCopyNode()
4303 ret->children = (xmlNodePtr) xmlGetDocEntity(doc, ret->name); in xmlStaticCopyNode()
4309 ret->children = xmlStaticCopyNodeList(node->children, doc, ret); in xmlStaticCopyNode()
4322 xmlStaticCopyNodeList(xmlNodePtr node, xmlDocPtr doc, xmlNodePtr parent) { in xmlStaticCopyNodeList() argument
4329 if (doc == NULL) { in xmlStaticCopyNodeList()
4333 if (doc->intSubset == NULL) { in xmlStaticCopyNodeList()
4336 q->doc = doc; in xmlStaticCopyNodeList()
4338 doc->intSubset = (xmlDtdPtr) q; in xmlStaticCopyNodeList()
4341 q = (xmlNodePtr) doc->intSubset; in xmlStaticCopyNodeList()
4346 q = xmlStaticCopyNode(node, doc, parent, 1); in xmlStaticCopyNodeList()
4394 xmlDocCopyNode(xmlNodePtr node, xmlDocPtr doc, int extended) { in xmlDocCopyNode() argument
4397 ret = xmlStaticCopyNode(node, doc, NULL, extended); in xmlDocCopyNode()
4410 xmlNodePtr xmlDocCopyNodeList(xmlDocPtr doc, xmlNodePtr node) { in xmlDocCopyNodeList() argument
4411 xmlNodePtr ret = xmlStaticCopyNodeList(node, doc, NULL); in xmlDocCopyNodeList()
4528 xmlCopyDoc(xmlDocPtr doc, int recursive) { in xmlCopyDoc() argument
4531 if (doc == NULL) return(NULL); in xmlCopyDoc()
4532 ret = xmlNewDoc(doc->version); in xmlCopyDoc()
4534 if (doc->name != NULL) in xmlCopyDoc()
4535 ret->name = xmlMemStrdup(doc->name); in xmlCopyDoc()
4536 if (doc->encoding != NULL) in xmlCopyDoc()
4537 ret->encoding = xmlStrdup(doc->encoding); in xmlCopyDoc()
4538 if (doc->URL != NULL) in xmlCopyDoc()
4539 ret->URL = xmlStrdup(doc->URL); in xmlCopyDoc()
4540 ret->charset = doc->charset; in xmlCopyDoc()
4541 ret->compression = doc->compression; in xmlCopyDoc()
4542 ret->standalone = doc->standalone; in xmlCopyDoc()
4548 if (doc->intSubset != NULL) { in xmlCopyDoc()
4549 ret->intSubset = xmlCopyDtd(doc->intSubset); in xmlCopyDoc()
4558 if (doc->oldNs != NULL) in xmlCopyDoc()
4559 ret->oldNs = xmlCopyNamespaceList(doc->oldNs); in xmlCopyDoc()
4560 if (doc->children != NULL) { in xmlCopyDoc()
4563 ret->children = xmlStaticCopyNodeList(doc->children, ret, in xmlCopyDoc()
4906 xmlDocGetRootElement(const xmlDoc *doc) { in xmlDocGetRootElement() argument
4909 if (doc == NULL) return(NULL); in xmlDocGetRootElement()
4910 ret = doc->children; in xmlDocGetRootElement()
4932 xmlDocSetRootElement(xmlDocPtr doc, xmlNodePtr root) { in xmlDocSetRootElement() argument
4935 if (doc == NULL) return(NULL); in xmlDocSetRootElement()
4939 xmlSetTreeDoc(root, doc); in xmlDocSetRootElement()
4940 root->parent = (xmlNodePtr) doc; in xmlDocSetRootElement()
4941 old = doc->children; in xmlDocSetRootElement()
4948 if (doc->children == NULL) { in xmlDocSetRootElement()
4949 doc->children = root; in xmlDocSetRootElement()
4950 doc->last = root; in xmlDocSetRootElement()
4952 xmlAddSibling(doc->children, root); in xmlDocSetRootElement()
5002 ns = xmlSearchNsByHref(cur->doc, cur, XML_XML_NAMESPACE); in xmlNodeSetLang()
5076 ns = xmlSearchNsByHref(cur->doc, cur, XML_XML_NAMESPACE); in xmlNodeSetSpacePreserve()
5134 xmlDocPtr doc; in xmlNodeSetName() local
5167 doc = cur->doc; in xmlNodeSetName()
5168 if (doc != NULL) in xmlNodeSetName()
5169 dict = doc->dict; in xmlNodeSetName()
5228 xmlDocPtr doc = (xmlDocPtr) cur; in xmlNodeSetBase() local
5230 if (doc->URL != NULL) in xmlNodeSetBase()
5231 xmlFree((xmlChar *) doc->URL); in xmlNodeSetBase()
5233 doc->URL = NULL; in xmlNodeSetBase()
5235 doc->URL = xmlPathToURI(uri); in xmlNodeSetBase()
5240 ns = xmlSearchNsByHref(cur->doc, cur, XML_XML_NAMESPACE); in xmlNodeSetBase()
5271 xmlNodeGetBase(const xmlDoc *doc, const xmlNode *cur) { in xmlNodeGetBase() argument
5275 if ((cur == NULL) && (doc == NULL)) in xmlNodeGetBase()
5279 if (doc == NULL) doc = cur->doc; in xmlNodeGetBase()
5280 if ((doc != NULL) && (doc->type == XML_HTML_DOCUMENT_NODE)) { in xmlNodeGetBase()
5281 cur = doc->children; in xmlNodeGetBase()
5332 if ((doc != NULL) && (doc->URL != NULL)) { in xmlNodeGetBase()
5334 return(xmlStrdup(doc->URL)); in xmlNodeGetBase()
5335 newbase = xmlBuildURI(oldbase, doc->URL); in xmlNodeGetBase()
5464 ent = xmlGetDocEntity(cur->doc, cur->name); in xmlBufGetNodeContent()
5556 ent = xmlGetDocEntity(cur->doc, cur->name); in xmlNodeGetContent()
5643 cur->children = xmlStringGetNodeList(cur->doc, content); in xmlNodeSetContent()
5654 if (!((cur->doc != NULL) && (cur->doc->dict != NULL) && in xmlNodeSetContent()
5655 (xmlDictOwns(cur->doc->dict, cur->content)))) in xmlNodeSetContent()
5720 cur->children = xmlStringLenGetNodeList(cur->doc, content, len); in xmlNodeSetContentLen()
5732 if (!((cur->doc != NULL) && (cur->doc->dict != NULL) && in xmlNodeSetContentLen()
5733 (xmlDictOwns(cur->doc->dict, cur->content)))) in xmlNodeSetContentLen()
5818 ((cur->doc != NULL) && (cur->doc->dict != NULL) && in xmlNodeAddContentLen()
5819 xmlDictOwns(cur->doc->dict, cur->content))) { in xmlNodeAddContentLen()
5905 xmlGetNsList(const xmlDoc *doc ATTRIBUTE_UNUSED, const xmlNode *node) in xmlGetNsList()
5969 xmlTreeEnsureXMLDecl(xmlDocPtr doc) in xmlTreeEnsureXMLDecl() argument
5971 if (doc == NULL) in xmlTreeEnsureXMLDecl()
5973 if (doc->oldNs != NULL) in xmlTreeEnsureXMLDecl()
5974 return (doc->oldNs); in xmlTreeEnsureXMLDecl()
5987 doc->oldNs = ns; in xmlTreeEnsureXMLDecl()
6009 xmlSearchNs(xmlDocPtr doc, xmlNodePtr node, const xmlChar *nameSpace) { in xmlSearchNs() argument
6017 if ((doc == NULL) && (node->type == XML_ELEMENT_NODE)) { in xmlSearchNs()
6036 if (doc == NULL) { in xmlSearchNs()
6037 doc = node->doc; in xmlSearchNs()
6038 if (doc == NULL) in xmlSearchNs()
6044 if (doc->oldNs == NULL) in xmlSearchNs()
6045 return(xmlTreeEnsureXMLDecl(doc)); in xmlSearchNs()
6047 return(doc->oldNs); in xmlSearchNs()
6097 xmlNsInScope(xmlDocPtr doc ATTRIBUTE_UNUSED, xmlNodePtr node, in xmlNsInScope()
6138 xmlSearchNsByHref(xmlDocPtr doc, xmlNodePtr node, const xmlChar * href) in xmlSearchNsByHref() argument
6150 if ((doc == NULL) && (node->type == XML_ELEMENT_NODE)) { in xmlSearchNsByHref()
6169 if (doc == NULL) { in xmlSearchNsByHref()
6170 doc = node->doc; in xmlSearchNsByHref()
6171 if (doc == NULL) in xmlSearchNsByHref()
6177 if (doc->oldNs == NULL) in xmlSearchNsByHref()
6178 return(xmlTreeEnsureXMLDecl(doc)); in xmlSearchNsByHref()
6180 return(doc->oldNs); in xmlSearchNsByHref()
6194 (xmlNsInScope(doc, orig, node, cur->prefix) == 1)) in xmlSearchNsByHref()
6205 (xmlNsInScope(doc, orig, node, cur->prefix) == 1)) in xmlSearchNsByHref()
6230 xmlNewReconciliedNs(xmlDocPtr doc, xmlNodePtr tree, xmlNsPtr ns) { in xmlNewReconciliedNs() argument
6252 def = xmlSearchNsByHref(doc, tree, ns->href); in xmlNewReconciliedNs()
6265 def = xmlSearchNs(doc, tree, prefix); in xmlNewReconciliedNs()
6273 def = xmlSearchNs(doc, tree, prefix); in xmlNewReconciliedNs()
6299 xmlReconciliateNs(xmlDocPtr doc, xmlNodePtr tree) { in xmlReconciliateNs() argument
6311 if ((doc == NULL) || (doc->type != XML_DOCUMENT_NODE)) return(-1); in xmlReconciliateNs()
6312 if (node->doc != doc) return(-1); in xmlReconciliateNs()
6347 n = xmlNewReconciliedNs(doc, tree, node->ns); in xmlReconciliateNs()
6411 n = xmlNewReconciliedNs(doc, tree, attr->ns); in xmlReconciliateNs()
6524 if ((node->doc != NULL) && (node->doc->intSubset != NULL)) { in xmlGetPropNodeInternal()
6525 xmlDocPtr doc = node->doc; in xmlGetPropNodeInternal() local
6545 attrDecl = xmlGetDtdQAttrDesc(doc->intSubset, in xmlGetPropNodeInternal()
6547 if ((attrDecl == NULL) && (doc->extSubset != NULL)) { in xmlGetPropNodeInternal()
6548 attrDecl = xmlGetDtdQAttrDesc(doc->extSubset, in xmlGetPropNodeInternal()
6558 nsList = xmlGetNsList(node->doc, node); in xmlGetPropNodeInternal()
6567 attrDecl = xmlGetDtdQAttrDesc(doc->intSubset, elemQName, in xmlGetPropNodeInternal()
6571 if (doc->extSubset != NULL) { in xmlGetPropNodeInternal()
6572 attrDecl = xmlGetDtdQAttrDesc(doc->extSubset, elemQName, in xmlGetPropNodeInternal()
6616 ret = xmlNodeListGetString(prop->doc, prop->children, 1); in xmlGetPropNodeValueInternal()
6643 xmlDocPtr doc; in xmlHasProp() local
6663 doc = node->doc; in xmlHasProp()
6664 if (doc != NULL) { in xmlHasProp()
6666 if (doc->intSubset != NULL) { in xmlHasProp()
6667 attrDecl = xmlGetDtdAttrDesc(doc->intSubset, node->name, name); in xmlHasProp()
6668 if ((attrDecl == NULL) && (doc->extSubset != NULL)) in xmlHasProp()
6669 attrDecl = xmlGetDtdAttrDesc(doc->extSubset, node->name, name); in xmlHasProp()
6851 ns = xmlSearchNs(node->doc, node, prefix); in xmlSetProp()
6886 xmlRemoveID(node->doc, prop); in xmlSetNsProp()
6898 xmlTreeErr(XML_TREE_NOT_UTF8, (xmlNodePtr) node->doc, in xmlSetNsProp()
6900 if (node->doc != NULL) in xmlSetNsProp()
6901 node->doc->encoding = xmlStrdup(BAD_CAST "ISO-8859-1"); in xmlSetNsProp()
6903 prop->children = xmlNewDocText(node->doc, value); in xmlSetNsProp()
6914 xmlAddID(NULL, node->doc, value, prop); in xmlSetNsProp()
6994 ((node->doc != NULL) && (node->doc->dict != NULL) && in xmlTextConcat()
6995 xmlDictOwns(node->doc->dict, node->content))) { in xmlTextConcat()
7755 xmlGetDocCompressMode (const xmlDoc *doc) { in xmlGetDocCompressMode() argument
7756 if (doc == NULL) return(-1); in xmlGetDocCompressMode()
7757 return(doc->compression); in xmlGetDocCompressMode()
7769 xmlSetDocCompressMode (xmlDocPtr doc, int mode) { in xmlSetDocCompressMode() argument
7770 if (doc == NULL) return; in xmlSetDocCompressMode()
7771 if (mode < 0) doc->compression = 0; in xmlSetDocCompressMode()
7772 else if (mode > 9) doc->compression = 9; in xmlSetDocCompressMode()
7773 else doc->compression = mode; in xmlSetDocCompressMode()
7968 xmlDOMWrapStoreNs(xmlDocPtr doc, in xmlDOMWrapStoreNs() argument
7974 if (doc == NULL) in xmlDOMWrapStoreNs()
7976 ns = xmlTreeEnsureXMLDecl(doc); in xmlDOMWrapStoreNs()
8097 while ((cur != NULL) && (cur != (xmlNodePtr) cur->doc)) { in xmlDOMWrapNSNormGatherInScopeNs()
8218 xmlDOMWrapRemoveNode(xmlDOMWrapCtxtPtr ctxt, xmlDocPtr doc, in xmlDOMWrapRemoveNode() argument
8225 if ((node == NULL) || (doc == NULL) || (node->doc != doc)) in xmlDOMWrapRemoveNode()
8285 ns = xmlDOMWrapStoreNs(doc, node->ns->href, in xmlDOMWrapRemoveNode()
8351 xmlSearchNsByNamespaceStrict(xmlDocPtr doc, xmlNodePtr node, in xmlSearchNsByNamespaceStrict() argument
8358 if ((doc == NULL) || (nsName == NULL) || (retNs == NULL)) in xmlSearchNsByNamespaceStrict()
8365 *retNs = xmlTreeEnsureXMLDecl(doc); in xmlSearchNsByNamespaceStrict()
8411 ret = xmlNsInScope(doc, node, prev, ns->prefix); in xmlSearchNsByNamespaceStrict()
8435 } while ((cur != NULL) && (cur->doc != (xmlDocPtr) cur)); in xmlSearchNsByNamespaceStrict()
8453 xmlSearchNsByPrefixStrict(xmlDocPtr doc, xmlNodePtr node, in xmlSearchNsByPrefixStrict() argument
8460 if ((doc == NULL) || (node == NULL) || (node->type == XML_NAMESPACE_DECL)) in xmlSearchNsByPrefixStrict()
8467 *retNs = xmlTreeEnsureXMLDecl(doc); in xmlSearchNsByPrefixStrict()
8498 } while ((cur != NULL) && (cur->doc != (xmlDocPtr) cur)); in xmlSearchNsByPrefixStrict()
8518 xmlDOMWrapNSNormDeclareNsForced(xmlDocPtr doc, in xmlDOMWrapNSNormDeclareNsForced() argument
8530 if ((doc == NULL) || (elem == NULL) || (elem->type != XML_ELEMENT_NODE)) in xmlDOMWrapNSNormDeclareNsForced()
8544 ((xmlNodePtr) elem->parent->doc != elem->parent)) { in xmlDOMWrapNSNormDeclareNsForced()
8548 if (xmlSearchNsByPrefixStrict(doc, elem->parent, pref, NULL) == 1) in xmlDOMWrapNSNormDeclareNsForced()
8597 xmlDOMWrapNSNormAquireNormalizedNs(xmlDocPtr doc, in xmlDOMWrapNSNormAquireNormalizedNs() argument
8609 if ((doc == NULL) || (ns == NULL) || (retNs == NULL) || in xmlDOMWrapNSNormAquireNormalizedNs()
8621 *retNs = xmlTreeEnsureXMLDecl(doc); in xmlDOMWrapNSNormAquireNormalizedNs()
8671 tmpns = xmlDOMWrapStoreNs(doc, ns->href, ns->prefix); in xmlDOMWrapNSNormAquireNormalizedNs()
8686 tmpns = xmlDOMWrapNSNormDeclareNsForced(doc, elem, ns->href, in xmlDOMWrapNSNormAquireNormalizedNs()
8745 xmlDocPtr doc; in xmlDOMWrapReconcileNamespaces() local
8756 if ((elem == NULL) || (elem->doc == NULL) || in xmlDOMWrapReconcileNamespaces()
8760 doc = elem->doc; in xmlDOMWrapReconcileNamespaces()
8777 ((xmlNodePtr) elem->parent->doc != elem->parent)) { in xmlDOMWrapReconcileNamespaces()
8861 ((xmlNodePtr) elem->parent->doc != elem->parent)) { in xmlDOMWrapReconcileNamespaces()
8898 if (xmlDOMWrapNSNormAquireNormalizedNs(doc, curElem, in xmlDOMWrapReconcileNamespaces()
9055 if (cur->doc != sourceDoc) { in xmlDOMWrapAdoptBranch()
9067 (cur->doc == node->doc)) in xmlDOMWrapAdoptBranch()
9071 if (cur->doc != node->doc) in xmlDOMWrapAdoptBranch()
9074 cur->doc = destDoc; in xmlDOMWrapAdoptBranch()
9408 if ((node->doc != NULL) && (sourceDoc != NULL) && in xmlDOMWrapCloneNode()
9409 (node->doc != sourceDoc)) { in xmlDOMWrapCloneNode()
9416 sourceDoc = node->doc; in xmlDOMWrapCloneNode()
9434 if (cur->doc != sourceDoc) { in xmlDOMWrapCloneNode()
9516 clone->doc = destDoc; in xmlDOMWrapCloneNode()
9752 idVal = xmlNodeListGetString(cur->doc, cur->children, 1); in xmlDOMWrapCloneNode()
9910 attr->doc = destDoc; in xmlDOMWrapAdoptAttr()
9954 cur->doc = destDoc; in xmlDOMWrapAdoptAttr()
10039 ((destParent != NULL) && (destParent->doc != destDoc))) in xmlDOMWrapAdoptNode()
10044 if ((node->doc != NULL) && (sourceDoc != NULL) && in xmlDOMWrapAdoptNode()
10045 (node->doc != sourceDoc)) { in xmlDOMWrapAdoptNode()
10052 sourceDoc = node->doc; in xmlDOMWrapAdoptNode()
10086 cur->doc = destDoc; in xmlDOMWrapAdoptNode()