Lines Matching full:ctxt
246 xmlParserCtxtPtr ctxt) {
263 if ((ctxt != NULL) && (ctxt->sax != NULL)) {
264 warning = ctxt->sax->warning;
265 err = ctxt->sax->error;
266 ctxt->sax->warning = NULL;
267 ctxt->sax->error = NULL;
271 ret = defaultEntityLoader(URL, ID, ctxt);
274 ctxt->sax->warning = warning;
276 ctxt->sax->error = err;
294 ret = defaultEntityLoader((const char *)newURL, ID, ctxt);
297 ctxt->sax->warning = warning;
299 ctxt->sax->error = err;
314 ctxt->sax->error = err;
316 ctxt->sax->warning = warning;
318 warning(ctxt, "failed to load external entity \"%s\"\n", URL);
320 warning(ctxt, "failed to load external entity \"%s\"\n", ID);
624 xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
630 input = ctxt->input;
631 if ((input != NULL) && (input->filename == NULL) && (ctxt->inputNr > 1)) {
632 input = ctxt->inputTab[ctxt->inputNr - 2];
661 xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
667 input = ctxt->input;
668 if ((input != NULL) && (input->filename == NULL) && (ctxt->inputNr > 1)) {
669 input = ctxt->inputTab[ctxt->inputNr - 2];
699 xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
705 input = ctxt->input;
706 if ((input->filename == NULL) && (ctxt->inputNr > 1))
707 input = ctxt->inputTab[ctxt->inputNr - 2];
736 xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx;
742 input = ctxt->input;
743 if ((input->filename == NULL) && (ctxt->inputNr > 1))
744 input = ctxt->inputTab[ctxt->inputNr - 2];
877 * @ctxt: An XML parser context
895 * @ctxt: An XML parser context
913 * @ctxt: An XML parser context
931 * @ctxt: An XML parser context
955 * @ctxt: An XML parser context
979 * @ctxt: An XML parser context
997 /* xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) ctx; */
1014 * @ctxt: An XML parser context
1033 * @ctxt: An XML parser context
1053 * @ctxt: An XML parser context
1083 * @ctxt: An XML parser context
1108 * @ctxt: An XML parser context
1128 * @ctxt: An XML parser context
1148 * @ctxt: An XML parser context
1179 * @ctxt: An XML parser context
1196 * @ctxt: An XML parser context
1211 * @ctxt: An XML parser context
1226 * @ctxt: An XML parser context
1252 * @ctxt: An XML parser context
1268 * @ctxt: An XML parser context
1293 * @ctxt: An XML parser context
1309 * @ctxt: An XML parser context
1334 * @ctxt: An XML parser context
1376 * @ctxt: An XML parser context
1392 * @ctxt: An XML parser context
1415 * @ctxt: An XML parser context
1438 * @ctxt: An XML parser context
1501 * @ctxt: An XML parser context
1558 * @ctxt: An XML parser context
1626 xmlParserCtxtPtr ctxt = NULL;
1682 ctxt = xmlNewParserCtxt();
1683 if (ctxt == NULL) {
1687 old_sax = ctxt->sax;
1688 ctxt->sax = handler;
1689 ctxt->userData = (void *) user_data;
1690 inputStream = xmlNewIOInputStream(ctxt, buf, XML_CHAR_ENCODING_NONE);
1695 inputPush(ctxt, inputStream);
1698 xmlParseDocument(ctxt);
1700 if (ctxt->myDoc != NULL) {
1702 xmlFreeDoc(ctxt->myDoc);
1703 ctxt->myDoc = NULL;
1708 if (ctxt != NULL) {
1709 ctxt->sax = old_sax;
1710 xmlFreeParserCtxt(ctxt);
2074 xmlSaveCtxtPtr ctxt;
2081 ctxt = xmlSaveToFd(1, NULL, 0);
2082 if (ctxt == NULL) {
2089 xmlSaveTree(ctxt, node);
2091 xmlSaveClose(ctxt);
2132 xmlXPathContextPtr ctxt;
2135 ctxt = xmlXPathNewContext(doc);
2136 if (ctxt == NULL) {
2141 ctxt->node = (xmlNodePtr) doc;
2142 res = xmlXPathEval(BAD_CAST query, ctxt);
2143 xmlXPathFreeContext(ctxt);
2197 htmlParserCtxtPtr ctxt;
2201 ctxt = htmlCreatePushParserCtxt(NULL, NULL,
2203 xmlCtxtUseOptions(ctxt, options);
2205 htmlParseChunk(ctxt, chars, res, 0);
2207 htmlParseChunk(ctxt, chars, 0, 1);
2208 doc = ctxt->myDoc;
2209 htmlFreeParserCtxt(ctxt);
2267 xmlParserCtxtPtr ctxt;
2272 ctxt = xmlCreatePushParserCtxt(NULL, NULL,
2274 xmlCtxtUseOptions(ctxt, options);
2276 xmlParseChunk(ctxt, chars, res, 0);
2278 xmlParseChunk(ctxt, chars, 0, 1);
2279 doc = ctxt->myDoc;
2280 ret = ctxt->wellFormed;
2281 xmlFreeParserCtxt(ctxt);
2316 xmlParserCtxtPtr ctxt;
2319 ctxt = xmlNewParserCtxt();
2321 ctxt = rectxt;
2322 if (ctxt == NULL) {
2325 ctxt->sax->error = xmlHTMLError;
2326 ctxt->sax->warning = xmlHTMLWarning;
2327 ctxt->vctxt.error = xmlHTMLValidityError;
2328 ctxt->vctxt.warning = xmlHTMLValidityWarning;
2330 doc = xmlCtxtReadFile(ctxt, filename, NULL, options);
2333 xmlFreeParserCtxt(ctxt);
2364 xmlParserCtxtPtr ctxt = NULL;
2367 ctxt = xmlNewParserCtxt();
2369 ctxt = rectxt;
2370 if (ctxt == NULL) {
2373 doc = xmlCtxtReadFile(ctxt, filename, NULL, options);
2375 if (ctxt->valid == 0)
2378 xmlFreeParserCtxt(ctxt);
2675 xmlSaveCtxtPtr ctxt;
2689 ctxt = xmlSaveToFd(1, encoding, saveOpts);
2691 ctxt = xmlSaveToFilename(output, encoding, saveOpts);
2693 if (ctxt != NULL) {
2694 if (xmlSaveDoc(ctxt, doc) < 0) {
2699 xmlSaveClose(ctxt);
2814 xmlSchematronValidCtxtPtr ctxt;
2828 ctxt = xmlSchematronNewValidCtxt(wxschematron, flag);
2830 xmlSchematronSetValidErrors(ctxt,
2835 ret = xmlSchematronValidateDoc(ctxt, doc);
2846 xmlSchematronFreeValidCtxt(ctxt);
2854 xmlRelaxNGValidCtxtPtr ctxt;
2861 ctxt = xmlRelaxNGNewValidCtxt(relaxngschemas);
2862 xmlRelaxNGSetValidErrors(ctxt,
2866 ret = xmlRelaxNGValidateDoc(ctxt, doc);
2877 xmlRelaxNGFreeValidCtxt(ctxt);
2882 xmlSchemaValidCtxtPtr ctxt;
2889 ctxt = xmlSchemaNewValidCtxt(wxschemas);
2890 xmlSchemaSetValidErrors(ctxt,
2894 ret = xmlSchemaValidateDoc(ctxt, doc);
2905 xmlSchemaFreeValidCtxt(ctxt);
3544 xmlSchematronParserCtxtPtr ctxt;
3552 ctxt = xmlSchematronNewParserCtxt(schematron);
3554 xmlSchematronSetParserErrors(ctxt,
3559 wxschematron = xmlSchematronParse(ctxt);
3566 xmlSchematronFreeParserCtxt(ctxt);
3578 xmlRelaxNGParserCtxtPtr ctxt;
3586 ctxt = xmlRelaxNGNewParserCtxt(relaxng);
3587 xmlRelaxNGSetParserErrors(ctxt,
3591 relaxngschemas = xmlRelaxNGParse(ctxt);
3598 xmlRelaxNGFreeParserCtxt(ctxt);
3607 xmlSchemaParserCtxtPtr ctxt;
3612 ctxt = xmlSchemaNewParserCtxt(schema);
3613 xmlSchemaSetParserErrors(ctxt,
3617 wxschemas = xmlSchemaParse(ctxt);
3624 xmlSchemaFreeParserCtxt(ctxt);
3717 xmlParserCtxtPtr ctxt = NULL;
3728 if (ctxt == NULL)
3729 ctxt = xmlNewParserCtxt();
3730 parseAndPrintFile(argv[i], ctxt);
3736 if (ctxt != NULL)
3737 xmlFreeParserCtxt(ctxt);