• Home
  • Raw
  • Download

Lines Matching refs:ctxt

360 xmlSaveCtxtInit(xmlSaveCtxtPtr ctxt)  in xmlSaveCtxtInit()  argument
365 if (ctxt == NULL) return; in xmlSaveCtxtInit()
366 if ((ctxt->encoding == NULL) && (ctxt->escape == NULL)) in xmlSaveCtxtInit()
367 ctxt->escape = xmlEscapeEntities; in xmlSaveCtxtInit()
370 memset(&ctxt->indent[0], 0, MAX_INDENT + 1); in xmlSaveCtxtInit()
372 ctxt->indent_size = len; in xmlSaveCtxtInit()
373 ctxt->indent_nr = MAX_INDENT / ctxt->indent_size; in xmlSaveCtxtInit()
374 for (i = 0;i < ctxt->indent_nr;i++) in xmlSaveCtxtInit()
375 memcpy(&ctxt->indent[i * ctxt->indent_size], xmlTreeIndentString, in xmlSaveCtxtInit()
376 ctxt->indent_size); in xmlSaveCtxtInit()
377 ctxt->indent[ctxt->indent_nr * ctxt->indent_size] = 0; in xmlSaveCtxtInit()
381 ctxt->options |= XML_SAVE_NO_EMPTY; in xmlSaveCtxtInit()
391 xmlFreeSaveCtxt(xmlSaveCtxtPtr ctxt) in xmlFreeSaveCtxt() argument
393 if (ctxt == NULL) return; in xmlFreeSaveCtxt()
394 if (ctxt->encoding != NULL) in xmlFreeSaveCtxt()
395 xmlFree((char *) ctxt->encoding); in xmlFreeSaveCtxt()
396 if (ctxt->buf != NULL) in xmlFreeSaveCtxt()
397 xmlOutputBufferClose(ctxt->buf); in xmlFreeSaveCtxt()
398 xmlFree(ctxt); in xmlFreeSaveCtxt()
585 static int xmlSaveSwitchEncoding(xmlSaveCtxtPtr ctxt, const char *encoding) { in xmlSaveSwitchEncoding() argument
586 xmlOutputBufferPtr buf = ctxt->buf; in xmlSaveSwitchEncoding()
609 static int xmlSaveClearEncoding(xmlSaveCtxtPtr ctxt) { in xmlSaveClearEncoding() argument
610 xmlOutputBufferPtr buf = ctxt->buf; in xmlSaveClearEncoding()
621 xhtmlNodeDumpOutput(xmlSaveCtxtPtr ctxt, xmlNodePtr cur);
623 static void xmlNodeListDumpOutput(xmlSaveCtxtPtr ctxt, xmlNodePtr cur);
624 static void xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur);
626 static int xmlDocContentDumpOutput(xmlSaveCtxtPtr ctxt, xmlDocPtr cur);
636 xmlOutputBufferWriteWSNonSig(xmlSaveCtxtPtr ctxt, int extra) in xmlOutputBufferWriteWSNonSig() argument
639 if ((ctxt == NULL) || (ctxt->buf == NULL)) in xmlOutputBufferWriteWSNonSig()
641 xmlOutputBufferWrite(ctxt->buf, 1, "\n"); in xmlOutputBufferWriteWSNonSig()
642 for (i = 0; i < (ctxt->level + extra); i += ctxt->indent_nr) { in xmlOutputBufferWriteWSNonSig()
643 xmlOutputBufferWrite(ctxt->buf, ctxt->indent_size * in xmlOutputBufferWriteWSNonSig()
644 ((ctxt->level + extra - i) > ctxt->indent_nr ? in xmlOutputBufferWriteWSNonSig()
645 ctxt->indent_nr : (ctxt->level + extra - i)), in xmlOutputBufferWriteWSNonSig()
646 ctxt->indent); in xmlOutputBufferWriteWSNonSig()
661 xmlNsDumpOutput(xmlOutputBufferPtr buf, xmlNsPtr cur, xmlSaveCtxtPtr ctxt) { in xmlNsDumpOutput() argument
667 if (ctxt != NULL && ctxt->format == 2) in xmlNsDumpOutput()
668 xmlOutputBufferWriteWSNonSig(ctxt, 2); in xmlNsDumpOutput()
692 xmlNsDumpOutputCtxt(xmlSaveCtxtPtr ctxt, xmlNsPtr cur) { in xmlNsDumpOutputCtxt() argument
693 xmlNsDumpOutput(ctxt->buf, cur, ctxt); in xmlNsDumpOutputCtxt()
705 xmlNsListDumpOutputCtxt(xmlSaveCtxtPtr ctxt, xmlNsPtr cur) { in xmlNsListDumpOutputCtxt() argument
707 xmlNsDumpOutput(ctxt->buf, cur, ctxt); in xmlNsListDumpOutputCtxt()
736 xmlDtdDumpOutput(xmlSaveCtxtPtr ctxt, xmlDtdPtr dtd) { in xmlDtdDumpOutput() argument
742 if ((ctxt == NULL) || (ctxt->buf == NULL)) in xmlDtdDumpOutput()
744 buf = ctxt->buf; in xmlDtdDumpOutput()
772 format = ctxt->format; in xmlDtdDumpOutput()
773 level = ctxt->level; in xmlDtdDumpOutput()
774 doc = ctxt->doc; in xmlDtdDumpOutput()
775 ctxt->format = 0; in xmlDtdDumpOutput()
776 ctxt->level = -1; in xmlDtdDumpOutput()
777 ctxt->doc = dtd->doc; in xmlDtdDumpOutput()
778 xmlNodeListDumpOutput(ctxt, dtd->children); in xmlDtdDumpOutput()
779 ctxt->format = format; in xmlDtdDumpOutput()
780 ctxt->level = level; in xmlDtdDumpOutput()
781 ctxt->doc = doc; in xmlDtdDumpOutput()
793 xmlAttrDumpOutput(xmlSaveCtxtPtr ctxt, xmlAttrPtr cur) { in xmlAttrDumpOutput() argument
797 buf = ctxt->buf; in xmlAttrDumpOutput()
799 if (ctxt->format == 2) in xmlAttrDumpOutput()
800 xmlOutputBufferWriteWSNonSig(ctxt, 2); in xmlAttrDumpOutput()
823 xmlAttrListDumpOutput(xmlSaveCtxtPtr ctxt, xmlAttrPtr cur) { in xmlAttrListDumpOutput() argument
826 xmlAttrDumpOutput(ctxt, cur); in xmlAttrListDumpOutput()
840 xmlNodeListDumpOutput(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { in xmlNodeListDumpOutput() argument
844 buf = ctxt->buf; in xmlNodeListDumpOutput()
846 if ((ctxt->format == 1) && (xmlIndentTreeOutput) && in xmlNodeListDumpOutput()
850 xmlOutputBufferWrite(buf, ctxt->indent_size * in xmlNodeListDumpOutput()
851 (ctxt->level > ctxt->indent_nr ? in xmlNodeListDumpOutput()
852 ctxt->indent_nr : ctxt->level), in xmlNodeListDumpOutput()
853 ctxt->indent); in xmlNodeListDumpOutput()
854 xmlNodeDumpOutputInternal(ctxt, cur); in xmlNodeListDumpOutput()
855 if (ctxt->format == 1) { in xmlNodeListDumpOutput()
870 htmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { in htmlNodeDumpOutputInternal() argument
872 const xmlChar *oldctxtenc = ctxt->encoding; in htmlNodeDumpOutputInternal()
873 const xmlChar *encoding = ctxt->encoding; in htmlNodeDumpOutputInternal()
874 xmlOutputBufferPtr buf = ctxt->buf; in htmlNodeDumpOutputInternal()
883 if (ctxt->encoding != NULL) { in htmlNodeDumpOutputInternal()
884 doc->encoding = BAD_CAST ctxt->encoding; in htmlNodeDumpOutputInternal()
898 if (xmlSaveSwitchEncoding(ctxt, (const char*) encoding) < 0) { in htmlNodeDumpOutputInternal()
904 if (ctxt->options & XML_SAVE_FORMAT) in htmlNodeDumpOutputInternal()
914 xmlSaveClearEncoding(ctxt); in htmlNodeDumpOutputInternal()
929 xmlNodeDumpOutputInternal(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { in xmlNodeDumpOutputInternal() argument
936 buf = ctxt->buf; in xmlNodeDumpOutputInternal()
943 xmlDocContentDumpOutput(ctxt, (xmlDocPtr) cur); in xmlNodeDumpOutputInternal()
947 if (ctxt->options & XML_SAVE_XHTML) { in xmlNodeDumpOutputInternal()
948 xhtmlNodeDumpOutput(ctxt, cur); in xmlNodeDumpOutputInternal()
953 ((ctxt->options & XML_SAVE_AS_XML) == 0)) || in xmlNodeDumpOutputInternal()
954 (ctxt->options & XML_SAVE_AS_HTML)) { in xmlNodeDumpOutputInternal()
955 htmlNodeDumpOutputInternal(ctxt, cur); in xmlNodeDumpOutputInternal()
960 xmlDtdDumpOutput(ctxt, (xmlDtdPtr) cur); in xmlNodeDumpOutputInternal()
964 xmlNodeListDumpOutput(ctxt, cur->children); in xmlNodeDumpOutputInternal()
982 xmlOutputBufferWriteEscape(buf, cur->content, ctxt->escape); in xmlNodeDumpOutputInternal()
998 if (ctxt->format == 2) in xmlNodeDumpOutputInternal()
999 xmlOutputBufferWriteWSNonSig(ctxt, 0); in xmlNodeDumpOutputInternal()
1008 if (ctxt->format == 2) in xmlNodeDumpOutputInternal()
1009 xmlOutputBufferWriteWSNonSig(ctxt, 0); in xmlNodeDumpOutputInternal()
1053 xmlAttrDumpOutput(ctxt, (xmlAttrPtr) cur); in xmlNodeDumpOutputInternal()
1057 xmlNsDumpOutputCtxt(ctxt, (xmlNsPtr) cur); in xmlNodeDumpOutputInternal()
1061 format = ctxt->format; in xmlNodeDumpOutputInternal()
1068 ctxt->format = 0; in xmlNodeDumpOutputInternal()
1082 xmlNsListDumpOutputCtxt(ctxt, cur->nsDef); in xmlNodeDumpOutputInternal()
1084 xmlAttrListDumpOutput(ctxt, cur->properties); in xmlNodeDumpOutputInternal()
1087 (cur->children == NULL) && ((ctxt->options & XML_SAVE_NO_EMPTY) == 0)) { in xmlNodeDumpOutputInternal()
1088 if (ctxt->format == 2) in xmlNodeDumpOutputInternal()
1089 xmlOutputBufferWriteWSNonSig(ctxt, 0); in xmlNodeDumpOutputInternal()
1091 ctxt->format = format; in xmlNodeDumpOutputInternal()
1094 if (ctxt->format == 2) in xmlNodeDumpOutputInternal()
1095 xmlOutputBufferWriteWSNonSig(ctxt, 1); in xmlNodeDumpOutputInternal()
1098 xmlOutputBufferWriteEscape(buf, cur->content, ctxt->escape); in xmlNodeDumpOutputInternal()
1101 if (ctxt->format == 1) xmlOutputBufferWrite(buf, 1, "\n"); in xmlNodeDumpOutputInternal()
1102 if (ctxt->level >= 0) ctxt->level++; in xmlNodeDumpOutputInternal()
1103 xmlNodeListDumpOutput(ctxt, cur->children); in xmlNodeDumpOutputInternal()
1104 if (ctxt->level > 0) ctxt->level--; in xmlNodeDumpOutputInternal()
1105 if ((xmlIndentTreeOutput) && (ctxt->format == 1)) in xmlNodeDumpOutputInternal()
1106 xmlOutputBufferWrite(buf, ctxt->indent_size * in xmlNodeDumpOutputInternal()
1107 (ctxt->level > ctxt->indent_nr ? in xmlNodeDumpOutputInternal()
1108 ctxt->indent_nr : ctxt->level), in xmlNodeDumpOutputInternal()
1109 ctxt->indent); in xmlNodeDumpOutputInternal()
1118 if (ctxt->format == 2) in xmlNodeDumpOutputInternal()
1119 xmlOutputBufferWriteWSNonSig(ctxt, 0); in xmlNodeDumpOutputInternal()
1121 ctxt->format = format; in xmlNodeDumpOutputInternal()
1131 xmlDocContentDumpOutput(xmlSaveCtxtPtr ctxt, xmlDocPtr cur) { in xmlDocContentDumpOutput() argument
1137 const xmlChar *oldctxtenc = ctxt->encoding; in xmlDocContentDumpOutput()
1138 const xmlChar *encoding = ctxt->encoding; in xmlDocContentDumpOutput()
1139 xmlCharEncodingOutputFunc oldescape = ctxt->escape; in xmlDocContentDumpOutput()
1140 xmlCharEncodingOutputFunc oldescapeAttr = ctxt->escapeAttr; in xmlDocContentDumpOutput()
1141 xmlOutputBufferPtr buf = ctxt->buf; in xmlDocContentDumpOutput()
1151 if (ctxt->encoding != NULL) { in xmlDocContentDumpOutput()
1152 cur->encoding = BAD_CAST ctxt->encoding; in xmlDocContentDumpOutput()
1158 ((ctxt->options & XML_SAVE_AS_XML) == 0) && in xmlDocContentDumpOutput()
1159 ((ctxt->options & XML_SAVE_XHTML) == 0)) || in xmlDocContentDumpOutput()
1160 (ctxt->options & XML_SAVE_AS_HTML)) { in xmlDocContentDumpOutput()
1170 if (xmlSaveSwitchEncoding(ctxt, (const char*) encoding) < 0) { in xmlDocContentDumpOutput()
1175 if (ctxt->options & XML_SAVE_FORMAT) in xmlDocContentDumpOutput()
1181 if (ctxt->encoding != NULL) in xmlDocContentDumpOutput()
1188 (ctxt->options & XML_SAVE_AS_XML) || in xmlDocContentDumpOutput()
1189 (ctxt->options & XML_SAVE_XHTML)) { in xmlDocContentDumpOutput()
1193 ((ctxt->options & XML_SAVE_NO_DECL) == 0)) { in xmlDocContentDumpOutput()
1202 if (xmlSaveSwitchEncoding(ctxt, (const char*) encoding) < 0) { in xmlDocContentDumpOutput()
1208 if (ctxt->escape == xmlEscapeEntities) in xmlDocContentDumpOutput()
1209 ctxt->escape = NULL; in xmlDocContentDumpOutput()
1210 if (ctxt->escapeAttr == xmlEscapeEntities) in xmlDocContentDumpOutput()
1211 ctxt->escapeAttr = NULL; in xmlDocContentDumpOutput()
1218 if ((ctxt->options & XML_SAVE_NO_DECL) == 0) { in xmlDocContentDumpOutput()
1240 if (ctxt->options & XML_SAVE_XHTML) in xmlDocContentDumpOutput()
1242 if ((ctxt->options & XML_SAVE_NO_XHTML) == 0) { in xmlDocContentDumpOutput()
1254 ctxt->level = 0; in xmlDocContentDumpOutput()
1257 xhtmlNodeDumpOutput(ctxt, child); in xmlDocContentDumpOutput()
1260 xmlNodeDumpOutputInternal(ctxt, child); in xmlDocContentDumpOutput()
1271 xmlSaveClearEncoding(ctxt); in xmlDocContentDumpOutput()
1272 ctxt->escape = oldescape; in xmlDocContentDumpOutput()
1273 ctxt->escapeAttr = oldescapeAttr; in xmlDocContentDumpOutput()
1360 xhtmlAttrListDumpOutput(xmlSaveCtxtPtr ctxt, xmlAttrPtr cur) { in xhtmlAttrListDumpOutput() argument
1369 buf = ctxt->buf; in xhtmlAttrListDumpOutput()
1395 xmlAttrDumpOutput(ctxt, cur); in xhtmlAttrListDumpOutput()
1446 xhtmlNodeListDumpOutput(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { in xhtmlNodeListDumpOutput() argument
1450 buf = ctxt->buf; in xhtmlNodeListDumpOutput()
1452 if ((ctxt->format == 1) && (xmlIndentTreeOutput) && in xhtmlNodeListDumpOutput()
1454 xmlOutputBufferWrite(buf, ctxt->indent_size * in xhtmlNodeListDumpOutput()
1455 (ctxt->level > ctxt->indent_nr ? in xhtmlNodeListDumpOutput()
1456 ctxt->indent_nr : ctxt->level), in xhtmlNodeListDumpOutput()
1457 ctxt->indent); in xhtmlNodeListDumpOutput()
1458 xhtmlNodeDumpOutput(ctxt, cur); in xhtmlNodeListDumpOutput()
1459 if (ctxt->format == 1) { in xhtmlNodeListDumpOutput()
1478 xhtmlNodeDumpOutput(xmlSaveCtxtPtr ctxt, xmlNodePtr cur) { in xhtmlNodeDumpOutput() argument
1487 xmlDocContentDumpOutput(ctxt, (xmlDocPtr) cur); in xhtmlNodeDumpOutput()
1495 xmlNsDumpOutputCtxt(ctxt, (xmlNsPtr) cur); in xhtmlNodeDumpOutput()
1499 xmlDtdDumpOutput(ctxt, (xmlDtdPtr) cur); in xhtmlNodeDumpOutput()
1503 xhtmlNodeListDumpOutput(ctxt, cur->children); in xhtmlNodeDumpOutput()
1506 buf = ctxt->buf; in xhtmlNodeDumpOutput()
1523 xmlOutputBufferWriteEscape(buf, cur->content, ctxt->escape); in xhtmlNodeDumpOutput()
1588 xmlAttrDumpOutput(ctxt, (xmlAttrPtr) cur); in xhtmlNodeDumpOutput()
1592 format = ctxt->format; in xhtmlNodeDumpOutput()
1612 xmlNsListDumpOutputCtxt(ctxt, cur->nsDef); in xhtmlNodeDumpOutput()
1622 xhtmlAttrListDumpOutput(ctxt, cur->properties); in xhtmlNodeDumpOutput()
1660 if (ctxt->format == 1) { in xhtmlNodeDumpOutput()
1663 xmlOutputBufferWrite(buf, ctxt->indent_size * in xhtmlNodeDumpOutput()
1664 (ctxt->level + 1 > ctxt->indent_nr ? in xhtmlNodeDumpOutput()
1665 ctxt->indent_nr : ctxt->level + 1), ctxt->indent); in xhtmlNodeDumpOutput()
1669 if (ctxt->encoding) { in xhtmlNodeDumpOutput()
1670 xmlOutputBufferWriteString(buf, (const char *)ctxt->encoding); in xhtmlNodeDumpOutput()
1675 if (ctxt->format == 1) in xhtmlNodeDumpOutput()
1695 if (ctxt->format == 1) { in xhtmlNodeDumpOutput()
1698 xmlOutputBufferWrite(buf, ctxt->indent_size * in xhtmlNodeDumpOutput()
1699 (ctxt->level + 1 > ctxt->indent_nr ? in xhtmlNodeDumpOutput()
1700 ctxt->indent_nr : ctxt->level + 1), ctxt->indent); in xhtmlNodeDumpOutput()
1704 if (ctxt->encoding) { in xhtmlNodeDumpOutput()
1705 xmlOutputBufferWriteString(buf, (const char *)ctxt->encoding); in xhtmlNodeDumpOutput()
1712 xmlOutputBufferWriteEscape(buf, cur->content, ctxt->escape); in xhtmlNodeDumpOutput()
1737 int level = ctxt->level; in xhtmlNodeDumpOutput()
1738 int indent = ctxt->format; in xhtmlNodeDumpOutput()
1740 ctxt->level = 0; in xhtmlNodeDumpOutput()
1741 ctxt->format = 0; in xhtmlNodeDumpOutput()
1745 ctxt->level = level; in xhtmlNodeDumpOutput()
1746 ctxt->format = indent; in xhtmlNodeDumpOutput()
1773 int level = ctxt->level; in xhtmlNodeDumpOutput()
1774 int indent = ctxt->format; in xhtmlNodeDumpOutput()
1776 ctxt->level = 0; in xhtmlNodeDumpOutput()
1777 ctxt->format = 0; in xhtmlNodeDumpOutput()
1778 xhtmlNodeDumpOutput(ctxt, child); in xhtmlNodeDumpOutput()
1779 ctxt->level = level; in xhtmlNodeDumpOutput()
1780 ctxt->format = indent; in xhtmlNodeDumpOutput()
1788 int indent = ctxt->format; in xhtmlNodeDumpOutput()
1791 if (ctxt->level >= 0) ctxt->level++; in xhtmlNodeDumpOutput()
1792 ctxt->format = format; in xhtmlNodeDumpOutput()
1793 xhtmlNodeListDumpOutput(ctxt, cur->children); in xhtmlNodeDumpOutput()
1794 if (ctxt->level > 0) ctxt->level--; in xhtmlNodeDumpOutput()
1795 ctxt->format = indent; in xhtmlNodeDumpOutput()
1797 xmlOutputBufferWrite(buf, ctxt->indent_size * in xhtmlNodeDumpOutput()
1798 (ctxt->level > ctxt->indent_nr ? in xhtmlNodeDumpOutput()
1799 ctxt->indent_nr : ctxt->level), in xhtmlNodeDumpOutput()
1800 ctxt->indent); in xhtmlNodeDumpOutput()
1957 xmlSaveDoc(xmlSaveCtxtPtr ctxt, xmlDocPtr doc) in xmlSaveDoc() argument
1961 if ((ctxt == NULL) || (doc == NULL)) return(-1); in xmlSaveDoc()
1962 if (xmlDocContentDumpOutput(ctxt, doc) < 0) in xmlSaveDoc()
1979 xmlSaveTree(xmlSaveCtxtPtr ctxt, xmlNodePtr node) in xmlSaveTree() argument
1983 if ((ctxt == NULL) || (node == NULL)) return(-1); in xmlSaveTree()
1984 xmlNodeDumpOutputInternal(ctxt, node); in xmlSaveTree()
1998 xmlSaveFlush(xmlSaveCtxtPtr ctxt) in xmlSaveFlush() argument
2000 if (ctxt == NULL) return(-1); in xmlSaveFlush()
2001 if (ctxt->buf == NULL) return(-1); in xmlSaveFlush()
2002 return(xmlOutputBufferFlush(ctxt->buf)); in xmlSaveFlush()
2015 xmlSaveClose(xmlSaveCtxtPtr ctxt) in xmlSaveClose() argument
2019 if (ctxt == NULL) return(-1); in xmlSaveClose()
2020 ret = xmlSaveFlush(ctxt); in xmlSaveClose()
2021 xmlFreeSaveCtxt(ctxt); in xmlSaveClose()
2035 xmlSaveSetEscape(xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape) in xmlSaveSetEscape() argument
2037 if (ctxt == NULL) return(-1); in xmlSaveSetEscape()
2038 ctxt->escape = escape; in xmlSaveSetEscape()
2052 xmlSaveSetAttrEscape(xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape) in xmlSaveSetAttrEscape() argument
2054 if (ctxt == NULL) return(-1); in xmlSaveSetAttrEscape()
2055 ctxt->escapeAttr = escape; in xmlSaveSetAttrEscape()
2378 xmlSaveCtxt ctxt; in xmlNodeDumpOutput() local
2391 memset(&ctxt, 0, sizeof(ctxt)); in xmlNodeDumpOutput()
2392 ctxt.doc = doc; in xmlNodeDumpOutput()
2393 ctxt.buf = buf; in xmlNodeDumpOutput()
2394 ctxt.level = level; in xmlNodeDumpOutput()
2395 ctxt.format = format ? 1 : 0; in xmlNodeDumpOutput()
2396 ctxt.encoding = (const xmlChar *) encoding; in xmlNodeDumpOutput()
2397 xmlSaveCtxtInit(&ctxt); in xmlNodeDumpOutput()
2398 ctxt.options |= XML_SAVE_AS_XML; in xmlNodeDumpOutput()
2409 xhtmlNodeDumpOutput(&ctxt, cur); in xmlNodeDumpOutput()
2412 xmlNodeDumpOutputInternal(&ctxt, cur); in xmlNodeDumpOutput()
2434 xmlSaveCtxt ctxt; in xmlDocDumpFormatMemoryEnc() local
2477 memset(&ctxt, 0, sizeof(ctxt)); in xmlDocDumpFormatMemoryEnc()
2478 ctxt.doc = out_doc; in xmlDocDumpFormatMemoryEnc()
2479 ctxt.buf = out_buff; in xmlDocDumpFormatMemoryEnc()
2480 ctxt.level = 0; in xmlDocDumpFormatMemoryEnc()
2481 ctxt.format = format ? 1 : 0; in xmlDocDumpFormatMemoryEnc()
2482 ctxt.encoding = (const xmlChar *) txt_encoding; in xmlDocDumpFormatMemoryEnc()
2483 xmlSaveCtxtInit(&ctxt); in xmlDocDumpFormatMemoryEnc()
2484 ctxt.options |= XML_SAVE_AS_XML; in xmlDocDumpFormatMemoryEnc()
2485 xmlDocContentDumpOutput(&ctxt, out_doc); in xmlDocDumpFormatMemoryEnc()
2571 xmlSaveCtxt ctxt; in xmlDocFormatDump() local
2596 memset(&ctxt, 0, sizeof(ctxt)); in xmlDocFormatDump()
2597 ctxt.doc = cur; in xmlDocFormatDump()
2598 ctxt.buf = buf; in xmlDocFormatDump()
2599 ctxt.level = 0; in xmlDocFormatDump()
2600 ctxt.format = format ? 1 : 0; in xmlDocFormatDump()
2601 ctxt.encoding = (const xmlChar *) encoding; in xmlDocFormatDump()
2602 xmlSaveCtxtInit(&ctxt); in xmlDocFormatDump()
2603 ctxt.options |= XML_SAVE_AS_XML; in xmlDocFormatDump()
2604 xmlDocContentDumpOutput(&ctxt, cur); in xmlDocFormatDump()
2638 xmlSaveCtxt ctxt; in xmlSaveFileTo() local
2646 memset(&ctxt, 0, sizeof(ctxt)); in xmlSaveFileTo()
2647 ctxt.doc = cur; in xmlSaveFileTo()
2648 ctxt.buf = buf; in xmlSaveFileTo()
2649 ctxt.level = 0; in xmlSaveFileTo()
2650 ctxt.format = 0; in xmlSaveFileTo()
2651 ctxt.encoding = (const xmlChar *) encoding; in xmlSaveFileTo()
2652 xmlSaveCtxtInit(&ctxt); in xmlSaveFileTo()
2653 ctxt.options |= XML_SAVE_AS_XML; in xmlSaveFileTo()
2654 xmlDocContentDumpOutput(&ctxt, cur); in xmlSaveFileTo()
2676 xmlSaveCtxt ctxt; in xmlSaveFormatFileTo() local
2686 memset(&ctxt, 0, sizeof(ctxt)); in xmlSaveFormatFileTo()
2687 ctxt.doc = cur; in xmlSaveFormatFileTo()
2688 ctxt.buf = buf; in xmlSaveFormatFileTo()
2689 ctxt.level = 0; in xmlSaveFormatFileTo()
2690 ctxt.format = format ? 1 : 0; in xmlSaveFormatFileTo()
2691 ctxt.encoding = (const xmlChar *) encoding; in xmlSaveFormatFileTo()
2692 xmlSaveCtxtInit(&ctxt); in xmlSaveFormatFileTo()
2693 ctxt.options |= XML_SAVE_AS_XML; in xmlSaveFormatFileTo()
2694 xmlDocContentDumpOutput(&ctxt, cur); in xmlSaveFormatFileTo()
2715 xmlSaveCtxt ctxt; in xmlSaveFormatFileEnc() local
2741 memset(&ctxt, 0, sizeof(ctxt)); in xmlSaveFormatFileEnc()
2742 ctxt.doc = cur; in xmlSaveFormatFileEnc()
2743 ctxt.buf = buf; in xmlSaveFormatFileEnc()
2744 ctxt.level = 0; in xmlSaveFormatFileEnc()
2745 ctxt.format = format ? 1 : 0; in xmlSaveFormatFileEnc()
2746 ctxt.encoding = (const xmlChar *) encoding; in xmlSaveFormatFileEnc()
2747 xmlSaveCtxtInit(&ctxt); in xmlSaveFormatFileEnc()
2748 ctxt.options |= XML_SAVE_AS_XML; in xmlSaveFormatFileEnc()
2750 xmlDocContentDumpOutput(&ctxt, cur); in xmlSaveFormatFileEnc()