Home | History | Annotate | Download | only in libxml2

Lines Matching defs:pctxt

992     xmlSchemaParserCtxtPtr pctxt;
1095 xmlSchemaParseAttributeGroupRef(xmlSchemaParserCtxtPtr pctxt,
2088 xmlSchemaParserCtxtPtr pctxt = (xmlSchemaParserCtxtPtr) ctxt;
2090 pctxt->nberrors++;
2091 pctxt->err = error;
2092 channel = pctxt->error;
2094 channel = pctxt->warning;
2096 schannel = pctxt->serror;
2097 data = pctxt->errCtxt;
2282 xmlSchemaPInternalErr(xmlSchemaParserCtxtPtr pctxt,
2288 xmlSchemaInternalErr2(ACTXT_CAST pctxt, funcName, message,
2735 #define PERROR_INT(func, msg) xmlSchemaInternalErr(ACTXT_CAST pctxt, func, msg);
3526 xmlSchemaBucketCreate(xmlSchemaParserCtxtPtr pctxt,
3533 if (WXS_CONSTRUCTOR(pctxt)->mainSchema == NULL) {
3538 mainSchema = WXS_CONSTRUCTOR(pctxt)->mainSchema;
3569 if (! WXS_HAS_BUCKETS(pctxt)) {
3579 WXS_CONSTRUCTOR(pctxt)->mainBucket = ret;
3596 WXS_IMPBUCKET(ret)->schema = xmlSchemaNewSchema(pctxt);
3613 WXS_CONSTRUCTOR(pctxt)->dict);
3633 if (WXS_IS_BUCKET_IMPMAIN(WXS_CONSTRUCTOR(pctxt)->bucket->type))
3635 WXS_IMPBUCKET(WXS_CONSTRUCTOR(pctxt)->bucket);
3638 WXS_INCBUCKET(WXS_CONSTRUCTOR(pctxt)->bucket)->ownerImport;
3654 if (xmlSchemaItemListAdd(WXS_CONSTRUCTOR(pctxt)->buckets, ret) == -1)
5184 xmlSchemaAddAttributeUse(xmlSchemaParserCtxtPtr pctxt,
5189 if (pctxt == NULL)
5194 xmlSchemaPErrMemory(pctxt, "allocating attribute", NULL);
5201 WXS_ADD_LOCAL(pctxt, ret);
5212 xmlSchemaAddRedef(xmlSchemaParserCtxtPtr pctxt,
5223 xmlSchemaPErrMemory(pctxt,
5232 if (WXS_CONSTRUCTOR(pctxt)->redefs == NULL)
5233 WXS_CONSTRUCTOR(pctxt)->redefs = ret;
5235 WXS_CONSTRUCTOR(pctxt)->lastRedef->next = ret;
5236 WXS_CONSTRUCTOR(pctxt)->lastRedef = ret;
5254 xmlSchemaAddAttributeGroupDefinition(xmlSchemaParserCtxtPtr pctxt,
5262 if ((pctxt == NULL) || (name == NULL))
5268 xmlSchemaPErrMemory(pctxt, "allocating attribute group", NULL);
5279 if (pctxt->isRedefine) {
5280 pctxt->redef = xmlSchemaAddRedef(pctxt, pctxt->redefined,
5282 if (pctxt->redef == NULL) {
5286 pctxt->redefCounter = 0;
5288 WXS_ADD_GLOBAL(pctxt, ret);
5289 WXS_ADD_PENDING(pctxt, ret);
5385 xmlSchemaNewQNameRef(xmlSchemaParserCtxtPtr pctxt,
5395 xmlSchemaPErrMemory(pctxt,
5408 WXS_ADD_LOCAL(pctxt, ret);
5413 xmlSchemaAddAttributeUseProhib(xmlSchemaParserCtxtPtr pctxt)
5420 xmlSchemaPErrMemory(pctxt,
5426 WXS_ADD_LOCAL(pctxt, ret);
5667 xmlSchemaSubstGroupAdd(xmlSchemaParserCtxtPtr pctxt,
5673 if (WXS_SUBST_GROUPS(pctxt) == NULL) {
5674 WXS_SUBST_GROUPS(pctxt) = xmlHashCreateDict(10, pctxt->dict);
5675 if (WXS_SUBST_GROUPS(pctxt) == NULL)
5694 if (xmlHashAddEntry2(WXS_SUBST_GROUPS(pctxt),
5705 xmlSchemaSubstGroupGet(xmlSchemaParserCtxtPtr pctxt,
5708 if (WXS_SUBST_GROUPS(pctxt) == NULL)
5710 return(xmlHashLookup2(WXS_SUBST_GROUPS(pctxt),
5717 * @pctxt: a schema parser context
5726 xmlSchemaAddElementSubstitutionMember(xmlSchemaParserCtxtPtr pctxt,
5732 if ((pctxt == NULL) || (head == NULL) || (member == NULL))
5735 substGroup = xmlSchemaSubstGroupGet(pctxt, head);
5737 substGroup = xmlSchemaSubstGroupAdd(pctxt, head);
6213 xmlSchemaParseLocalAttribute(xmlSchemaParserCtxtPtr pctxt,
6243 xmlSchemaPValAttrNodeValue(xmlSchemaParserCtxtPtr pctxt,
6256 if ((pctxt == NULL) || (type == NULL) || (attr == NULL))
6291 xmlSchemaPSimpleTypeErr(pctxt,
6390 xmlSchemaCheckReference(xmlSchemaParserCtxtPtr pctxt,
6397 if (xmlStrEqual(pctxt->targetNamespace, namespaceName))
6404 if (WXS_BUCKET(pctxt)->relations != NULL) {
6407 rel = WXS_BUCKET(pctxt)->relations;
6422 xmlSchemaCustomErr(ACTXT_CAST pctxt,
6428 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7081 xmlSchemaParseLocalAttribute(xmlSchemaParserCtxtPtr pctxt,
7102 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7106 if (xmlSchemaPValAttrNodeQName(pctxt, schema,
7110 if (xmlSchemaCheckReference(pctxt, schema, node, attr, tmpNs) != 0)
7114 nberrors = pctxt->nberrors;
7123 xmlSchemaPValAttrNodeID(pctxt, attr);
7132 xmlSchemaPValAttrNodeID(pctxt, attr);
7135 xmlSchemaPValAttrNodeQName(pctxt, schema, NULL,
7143 attrValue = xmlSchemaGetNodeContent(pctxt,
7146 ns = pctxt->targetNamespace;
7149 xmlSchemaPSimpleTypeErr(pctxt,
7160 attrValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7169 xmlSchemaPSimpleTypeErr(pctxt,
7182 xmlSchemaPMutualExclAttrErr(pctxt,
7186 defValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7196 xmlSchemaPMutualExclAttrErr(pctxt,
7200 defValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7208 xmlSchemaPIllegalAttrErr(pctxt,
7221 xmlSchemaPSimpleTypeErr(pctxt,
7232 if (nberrors != pctxt->nberrors)
7239 ns = pctxt->targetNamespace;
7245 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7253 xmlSchemaPMissingAttrErr(pctxt, XML_SCHEMAP_S4S_ATTR_MISSING,
7257 if (xmlSchemaPValAttrNode(pctxt, NULL, attr,
7266 xmlSchemaPSimpleTypeErr(pctxt,
7279 use = xmlSchemaAddAttributeUse(pctxt, node);
7286 attrDecl = xmlSchemaAddAttribute(pctxt, schema, name, ns, node, 0);
7308 use = xmlSchemaAddAttributeUse(pctxt, node);
7314 WXS_ADD_PENDING(pctxt, use);
7319 ref = xmlSchemaNewQNameRef(pctxt, XML_SCHEMA_TYPE_ATTRIBUTE,
7346 xmlSchemaParseAnnotation(pctxt, child, 0);
7350 xmlSchemaPContentErr(pctxt,
7359 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
7367 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
7393 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
7407 prohib = xmlSchemaAddAttributeUseProhib(pctxt);
7417 WXS_ADD_PENDING(pctxt, prohib);
7425 use->annot = xmlSchemaParseAnnotation(pctxt, child, 1);
7436 xmlSchemaPContentErr(pctxt,
7441 xmlSchemaPContentErr(pctxt,
7453 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_SRC_ATTRIBUTE_4,
7459 xmlSchemaParseSimpleType(pctxt, schema, child, 0);
7463 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_S4S_ELEM_NOT_ALLOWED,
7473 xmlSchemaParseGlobalAttribute(xmlSchemaParserCtxtPtr pctxt,
7488 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7496 xmlSchemaPMissingAttrErr(pctxt, XML_SCHEMAP_S4S_ATTR_MISSING,
7500 if (xmlSchemaPValAttrNode(pctxt, NULL, attr,
7509 xmlSchemaPSimpleTypeErr(pctxt,
7523 if (xmlStrEqual(pctxt->targetNamespace, xmlSchemaInstanceNs)) {
7524 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7530 ret = xmlSchemaAddAttribute(pctxt, schema, attrValue,
7531 pctxt->targetNamespace, node, 1);
7548 xmlSchemaPIllegalAttrErr(pctxt,
7552 xmlSchemaPIllegalAttrErr(pctxt,
7557 xmlSchemaPValAttrQName(pctxt, schema, NULL,
7560 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
7564 ret->defValue = xmlSchemaGetProp(pctxt, node, "fixed");
7577 xmlSchemaPMutualExclAttrErr(pctxt, XML_SCHEMAP_SRC_ATTRIBUTE_1,
7580 ret->defValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7587 ret->annot = xmlSchemaParseAnnotation(pctxt, child, 1);
7596 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_SRC_ATTRIBUTE_4,
7601 ret->subtypes = xmlSchemaParseSimpleType(pctxt, schema, child, 0);
7605 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_S4S_ELEM_NOT_ALLOWED,
7626 xmlSchemaParseAttributeGroupRef(xmlSchemaParserCtxtPtr pctxt,
7635 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7640 xmlSchemaPMissingAttrErr(pctxt,
7645 xmlSchemaPValAttrNodeQName(pctxt, schema,
7647 if (xmlSchemaCheckReference(pctxt, schema, node, attr, refNs) != 0)
7659 xmlSchemaPIllegalAttrErr(pctxt,
7663 xmlSchemaPIllegalAttrErr(pctxt,
7669 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
7679 xmlSchemaParseAnnotation(pctxt, child, 0);
7683 xmlSchemaPContentErr(pctxt,
7692 if (pctxt->isRedefine && pctxt->redef &&
7693 (pctxt->redef->item->type ==
7695 (ref == pctxt->redef->refName) &&
7696 (refNs == pctxt->redef->refTargetNs))
7705 if (pctxt->redefCounter != 0) {
7708 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7717 pctxt->redefCounter++;
7722 ret = xmlSchemaNewQNameRef(pctxt,
7727 pctxt->redef->reference = WXS_BASIC_CAST ret;
7734 ret = xmlSchemaNewQNameRef(pctxt,
7740 WXS_ADD_PENDING(pctxt, ret);
7747 * @pctxt: a schema validation context
7757 xmlSchemaParseAttributeGroupDefinition(xmlSchemaParserCtxtPtr pctxt,
7767 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7772 xmlSchemaPMissingAttrErr(pctxt,
7780 if (xmlSchemaPValAttrNode(pctxt,
7785 ret = xmlSchemaAddAttributeGroupDefinition(pctxt, schema,
7786 name, pctxt->targetNamespace, node);
7798 xmlSchemaPIllegalAttrErr(pctxt,
7802 xmlSchemaPIllegalAttrErr(pctxt,
7808 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
7814 ret->annot = xmlSchemaParseAnnotation(pctxt, child, 1);
7820 if (xmlSchemaParseLocalAttributes(pctxt, schema, &child,
7830 ret->attributeWildcard = xmlSchemaParseAnyAttribute(pctxt,
7835 xmlSchemaPContentErr(pctxt,
9969 if (vctxt->pctxt == NULL) {
9971 vctxt->pctxt =
9974 vctxt->pctxt = xmlSchemaNewParserCtxt("*");
9975 if (vctxt->pctxt == NULL) {
9981 xmlSchemaSetParserErrors(vctxt->pctxt, vctxt->error,
9983 xmlSchemaSetParserStructuredErrors(vctxt->pctxt, vctxt->serror,
9991 * @pctxt: the schema parser context
10000 xmlSchemaGetSchemaBucket(xmlSchemaParserCtxtPtr pctxt,
10006 list = pctxt->constructor->buckets;
10022 xmlSchemaGetChameleonSchemaBucket(xmlSchemaParserCtxtPtr pctxt,
10029 list = pctxt->constructor->buckets;
10051 xmlSchemaGetSchemaBucketByTNS(xmlSchemaParserCtxtPtr pctxt,
10058 list = pctxt->constructor->buckets;
10076 xmlSchemaParseNewDocWithContext(xmlSchemaParserCtxtPtr pctxt,
10084 xmlSchemaBucketPtr oldbucket = pctxt->constructor->bucket;
10097 pctxt->schema = schema;
10102 pctxt->targetNamespace = bucket->targetNamespace;
10103 WXS_CONSTRUCTOR(pctxt)->bucket = bucket;
10110 pctxt->isS4S = 1;
10116 ret = xmlSchemaParseSchemaElement(pctxt, schema, node);
10122 oldErrs = pctxt->nberrors;
10123 ret = xmlSchemaParseSchemaTopLevel(pctxt, schema, node->children);
10128 * as a result of the obove functions; so better rely on pctxt->err
10131 if ((ret == 0) && (oldErrs != pctxt->nberrors)) {
10132 ret = pctxt->err;
10137 WXS_CONSTRUCTOR(pctxt)->bucket = oldbucket;
10145 xmlSchemaParseNewDoc(xmlSchemaParserCtxtPtr pctxt,
10164 if (pctxt->constructor == NULL) {
10171 (const char *) bucket->schemaLocation, pctxt->dict);
10174 newpctxt->constructor = pctxt->constructor;
10181 xmlSchemaSetParserErrors(newpctxt, pctxt->error, pctxt->warning,
10182 pctxt->errCtxt);
10183 xmlSchemaSetParserStructuredErrors(newpctxt, pctxt->serror,
10184 pctxt->errCtxt);
10185 newpctxt->counter = pctxt->counter;
10192 pctxt->err = res;
10193 pctxt->nberrors += newpctxt->nberrors;
10194 pctxt->counter = newpctxt->counter;
10252 * @pctxt: a schema validation context
10263 xmlSchemaAddSchemaDoc(xmlSchemaParserCtxtPtr pctxt,
10301 if ((type == XML_SCHEMA_SCHEMA_MAIN) || (! WXS_HAS_BUCKETS(pctxt)))
10306 bkt = xmlSchemaGetSchemaBucket(pctxt, schemaLocation);
10308 (pctxt->constructor->bucket == bkt)) {
10311 xmlSchemaCustomErr(ACTXT_CAST pctxt, err,
10324 xmlSchemaSchemaRelationAddChild(pctxt->constructor->bucket,
10351 xmlSchemaCustomErr(ACTXT_CAST pctxt, err,
10361 xmlSchemaCustomErr(ACTXT_CAST pctxt, err,
10395 bkt = xmlSchemaGetSchemaBucketByTNS(pctxt,
10414 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
10454 chamel = xmlSchemaGetChameleonSchemaBucket(pctxt,
10492 schemaLocation = xmlDictLookup(pctxt->dict,
10505 if ((pctxt->dict != NULL) && (parserCtxt->dict != NULL)) {
10511 parserCtxt->dict = pctxt->dict;
10555 xmlSchemaCustomErr(ACTXT_CAST pctxt, res,
10565 xmlSchemaPErr(pctxt, NULL,
10581 xmlSchemaCustomErr(ACTXT_CAST pctxt, XML_SCHEMAP_NOROOT,
10590 xmlSchemaCleanupDoc(pctxt, docElem);
10595 xmlSchemaCustomErr(ACTXT_CAST pctxt, XML_SCHEMAP_NOT_SCHEMA,
10605 targetNamespace = xmlSchemaGetProp(pctxt, docElem,
10612 bkt = xmlSchemaBucketCreate(pctxt, type,
10651 return(pctxt->err);
10675 xmlSchemaParseImport(xmlSchemaParserCtxtPtr pctxt, xmlSchemaPtr schema,
10685 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
10697 xmlSchemaPIllegalAttrErr(pctxt,
10701 xmlSchemaPIllegalAttrErr(pctxt,
10709 if (xmlSchemaPValAttr(pctxt, NULL, node,
10712 xmlSchemaPSimpleTypeErr(pctxt,
10717 return (pctxt->err);
10720 if (xmlSchemaPValAttr(pctxt, NULL, node,
10723 xmlSchemaPSimpleTypeErr(pctxt,
10728 return (pctxt->err);
10742 xmlSchemaPContentErr(pctxt,
10755 thisTargetNamespace = WXS_BUCKET(pctxt)->origTargetNamespace;
10763 xmlSchemaPCustomErr(pctxt,
10769 return (pctxt->err);
10777 xmlSchemaPCustomErr(pctxt,
10783 return (pctxt->err);
10790 schemaLocation = xmlSchemaBuildAbsoluteURI(pctxt->dict,
10792 ret = xmlSchemaAddSchemaDoc(pctxt, XML_SCHEMA_SCHEMA_IMPORT,
10807 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
10815 ret = xmlSchemaParseNewDoc(pctxt, schema, bucket);
10822 xmlSchemaParseIncludeOrRedefineAttrs(xmlSchemaParserCtxtPtr pctxt,
10830 if ((pctxt == NULL) || (schema == NULL) || (node == NULL) ||
10844 xmlSchemaPIllegalAttrErr(pctxt,
10848 xmlSchemaPIllegalAttrErr(pctxt,
10853 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
10866 if (xmlSchemaPValAttrNode(pctxt, NULL, attr,
10882 (*schemaLocation) = (xmlChar *) xmlDictLookup(pctxt->dict, uri, -1);
10885 xmlSchemaPMissingAttrErr(pctxt,
10893 if (xmlStrEqual(*schemaLocation, pctxt->URL)) {
10895 xmlSchemaPCustomErr(pctxt,
10901 xmlSchemaPCustomErr(pctxt,
10912 return(pctxt->err);
10918 xmlSchemaParseIncludeOrRedefine(xmlSchemaParserCtxtPtr pctxt,
10929 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
10936 res = xmlSchemaParseIncludeOrRedefineAttrs(pctxt, schema,
10943 res = xmlSchemaAddSchemaDoc(pctxt, type, schemaLocation, NULL,
10944 NULL, 0, node, pctxt->targetNamespace, NULL, &bucket);
10966 xmlSchemaCustomErr(ACTXT_CAST pctxt, res,
10983 xmlSchemaCustomErr(ACTXT_CAST pctxt, res,
11001 if (pctxt->targetNamespace == NULL) {
11002 xmlSchemaCustomErr(ACTXT_CAST pctxt,
11011 pctxt->targetNamespace)) {
11013 xmlSchemaPCustomErrExt(pctxt,
11020 pctxt->targetNamespace);
11023 } else if (pctxt->targetNamespace != NULL) {
11030 (bucket->targetNamespace != pctxt->targetNamespace)) {
11039 bucket->targetNamespace = pctxt->targetNamespace;
11053 xmlSchemaParseNewDoc(pctxt, schema, bucket);
11066 pctxt->redefined = bucket;
11070 pctxt->isRedefine = 1;
11081 xmlSchemaParseSimpleType(pctxt, schema, child, 1);
11083 xmlSchemaParseComplexType(pctxt, schema, child, 1);
11087 xmlSchemaParseModelGroupDefinition(pctxt,
11091 xmlSchemaParseAttributeGroupDefinition(pctxt, schema,
11096 pctxt->redefined = NULL;
11097 pctxt->isRedefine = 0;
11109 xmlSchemaPContentErr(pctxt, res,
11113 xmlSchemaPContentErr(pctxt, res,
11121 return(pctxt->err);
11125 xmlSchemaParseRedefine(xmlSchemaParserCtxtPtr pctxt, xmlSchemaPtr schema,
11133 res = xmlSchemaParseIncludeOrRedefine(pctxt, schema, node,
11141 xmlSchemaParseInclude(xmlSchemaParserCtxtPtr pctxt, xmlSchemaPtr schema,
11146 res = xmlSchemaParseIncludeOrRedefine(pctxt, schema, node,
12516 xmlSchemaBuildContentModelForSubstGroup(xmlSchemaParserCtxtPtr pctxt,
12528 start = pctxt->state;
12530 end = xmlAutomataNewState(pctxt->am);
12531 substGroup = xmlSchemaSubstGroupGet(pctxt, elemDecl);
12533 xmlSchemaPErr(pctxt, WXS_ITEM_NODE(particle),
12547 tmp = xmlAutomataNewCountedTrans(pctxt->am, start, NULL, counter);
12548 xmlAutomataNewTransition2(pctxt->am, tmp, end,
12555 xmlAutomataNewTransition2(pctxt->am, tmp, end,
12562 xmlAutomataNewEpsilon(pctxt->am,
12563 xmlAutomataNewTransition2(pctxt->am,
12580 * tmp = xmlAutomataNewOnceTrans2(pctxt->am, start, NULL,
12584 tmp = xmlAutomataNewTransition2(pctxt->am, start, NULL,
12586 xmlAutomataNewEpsilon(pctxt->am, tmp, end);
12595 xmlAutomataNewCounter(pctxt->am, minOccurs,
12597 hop = xmlAutomataNewState(pctxt->am);
12599 xmlAutomataNewEpsilon(pctxt->am,
12600 xmlAutomataNewTransition2(pctxt->am,
12609 xmlAutomataNewEpsilon(pctxt->am,
12610 xmlAutomataNewTransition2(pctxt->am,
12615 xmlAutomataNewCountedTrans(pctxt->am, hop, start, counter);
12616 xmlAutomataNewCounterTrans(pctxt->am, hop, end, counter);
12619 pctxt->am, start, end);
12620 pctxt->state = end;
12683 xmlSchemaBuildAContentModel(xmlSchemaParserCtxtPtr pctxt,
12706 start = pctxt->state;
12707 end = xmlAutomataNewState(pctxt->am);
12716 pctxt->state =
12717 xmlAutomataNewTransition2(pctxt->am,
12719 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12723 pctxt->state =
12724 xmlAutomataNewTransition2(pctxt->am,
12726 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12731 pctxt->state = start;
12732 pctxt->state = xmlAutomataNewTransition2(pctxt->am,
12733 pctxt->state, NULL, BAD_CAST "*", ns->value, wild);
12734 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12739 pctxt->state = xmlAutomataNewNegTrans(pctxt->am,
12751 counter = xmlAutomataNewCounter(pctxt->am, minOccurs, maxOccurs);
12752 hop = xmlAutomataNewState(pctxt->am);
12754 pctxt->state =
12755 xmlAutomataNewTransition2(pctxt->am,
12757 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12758 pctxt->state =
12759 xmlAutomataNewTransition2(pctxt->am,
12761 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12765 pctxt->state =
12766 xmlAutomataNewTransition2(pctxt->am,
12768 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12773 pctxt->state = xmlAutomataNewNegTrans(pctxt->am,
12777 xmlAutomataNewCountedTrans(pctxt->am, hop, start, counter);
12778 xmlAutomataNewCounterTrans(pctxt->am, hop, end, counter);
12781 xmlAutomataNewEpsilon(pctxt->am, start, end);
12783 pctxt->state = end;
12787 xmlSchemaBuildContentModelForElement(pctxt, particle);
12799 xmlSchemaBuildAContentModel(pctxt,
12804 xmlAutomataStatePtr oldstate = pctxt->state;
12811 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12813 oldstate = pctxt->state;
12815 counter = xmlAutomataNewCounter(pctxt->am,
12820 xmlSchemaBuildAContentModel(pctxt,
12824 tmp = pctxt->state;
12825 xmlAutomataNewCountedTrans(pctxt->am, tmp,
12827 pctxt->state =
12828 xmlAutomataNewCounterTrans(pctxt->am, tmp,
12832 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12834 oldstate = pctxt->state;
12838 xmlSchemaBuildAContentModel(pctxt,
12842 xmlAutomataNewEpsilon(pctxt->am, pctxt->state,
12849 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12850 pctxt->state, NULL);
12852 xmlAutomataNewEpsilon(pctxt->am,
12853 oldstate, pctxt->state);
12861 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12863 oldstate = pctxt->state;
12865 counter = xmlAutomataNewCounter(pctxt->am,
12871 xmlSchemaBuildAContentModel(pctxt,
12875 tmp = pctxt->state;
12876 xmlAutomataNewCountedTrans(pctxt->am,
12878 pctxt->state =
12879 xmlAutomataNewCounterTrans(pctxt->am, tmp, NULL,
12882 xmlAutomataNewEpsilon(pctxt->am,
12883 oldstate, pctxt->state);
12888 xmlSchemaBuildAContentModel(pctxt,
12893 xmlAutomataNewEpsilon(pctxt->am, oldstate,
12894 pctxt->state);
12904 start = pctxt->state;
12905 end = xmlAutomataNewState(pctxt->am);
12914 pctxt->state = start;
12915 xmlSchemaBuildAContentModel(pctxt,
12917 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12933 xmlAutomataNewCounter(pctxt->am, minOccurs, maxOccurs);
12934 hop = xmlAutomataNewState(pctxt->am);
12935 base = xmlAutomataNewState(pctxt->am);
12939 pctxt->state = base;
12940 xmlSchemaBuildAContentModel(pctxt,
12942 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12945 xmlAutomataNewEpsilon(pctxt->am, start, base);
12946 xmlAutomataNewCountedTrans(pctxt->am, hop, base, counter);
12947 xmlAutomataNewCounterTrans(pctxt->am, hop, end, counter);
12950 xmlAutomataNewEpsilon(pctxt->am, start, end);
12952 pctxt->state = end;
12964 start = pctxt->state;
12966 pctxt->state = start;
12988 counter = xmlAutomataNewCounter(pctxt->am,
12990 xmlSchemaBuildContentModelForSubstGroup(pctxt,
12991 sub, counter, pctxt->state);
12995 xmlAutomataNewOnceTrans2(pctxt->am, pctxt->state,
12996 pctxt->state,
13003 xmlAutomataNewCountTrans2(pctxt->am, pctxt->state,
13004 pctxt->state,
13015 pctxt->state =
13016 xmlAutomataNewAllTrans(pctxt->am, pctxt->state, NULL, lax);
13029 xmlSchemaInternalErr2(ACTXT_CAST pctxt,
14012 xmlSchemaCheckDerivationOKRestriction2to4(xmlSchemaParserCtxtPtr pctxt,
14056 xmlSchemaPAttrUseErr4(pctxt,
14066 /* err = pctxt->err; */
14067 } else if (xmlSchemaCheckCOSSTDerivedOK(ACTXT_CAST pctxt,
14079 xmlSchemaPAttrUseErr4(pctxt,
14096 /* err = pctxt->err; */
14130 xmlSchemaPAttrUseErr4(pctxt,
14141 /* err = pctxt->err; */
14163 xmlSchemaPAttrUseErr4(pctxt,
14172 /* err = pctxt->err; */
14206 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14234 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14244 return(pctxt->err);
14255 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14265 return(pctxt->err);
14277 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14287 return(pctxt->err);
14295 xmlSchemaExpandAttributeGroupRefs(xmlSchemaParserCtxtPtr pctxt,
14315 xmlSchemaFixupTypeAttributeUses(xmlSchemaParserCtxtPtr pctxt,
14329 if (xmlSchemaTypeFixup(baseType, ACTXT_CAST pctxt) == -1)
14343 * into pctxt->attrProhibs.
14345 if (xmlSchemaExpandAttributeGroupRefs(pctxt,
14347 pctxt->attrProhibs) == -1)
14352 if (pctxt->attrProhibs->nbItems != 0)
14353 prohibs = pctxt->attrProhibs;
14355 if (xmlSchemaExpandAttributeGroupRefs(pctxt,
14468 if (xmlSchemaUnionWildcards(pctxt, type->attributeWildcard,
14793 * @pctxt: the schema parser context
14804 xmlSchemaCheckTypeDefCircularInternal(xmlSchemaParserCtxtPtr pctxt,
14814 xmlSchemaPCustomErr(pctxt,
14827 ret = xmlSchemaCheckTypeDefCircularInternal(pctxt, ctxtType,
14867 xmlSchemaCheckUnionTypeDefCircularRecur(xmlSchemaParserCtxtPtr pctxt,
14880 pctxt,
14891 res = xmlSchemaCheckUnionTypeDefCircularRecur(pctxt,
14906 xmlSchemaCheckUnionTypeDefCircular(xmlSchemaParserCtxtPtr pctxt,
14911 return(xmlSchemaCheckUnionTypeDefCircularRecur(pctxt, type,
15157 xmlSchemaCheckCOSSTRestricts(xmlSchemaParserCtxtPtr pctxt,
15175 xmlSchemaPCustomErr(pctxt,
15189 xmlSchemaPCustomErr(pctxt,
15217 xmlSchemaPIllegalFacetAtomicErr(pctxt,
15245 xmlSchemaTypeFixup(itemType, ACTXT_CAST pctxt);
15253 xmlSchemaPCustomErr(pctxt,
15266 xmlSchemaPCustomErr(pctxt,
15291 xmlSchemaPCustomErr(pctxt,
15309 xmlSchemaPIllegalFacetListUnionErr(pctxt,
15334 xmlSchemaPCustomErr(pctxt,
15348 xmlSchemaPCustomErr(pctxt,
15371 (xmlSchemaCheckCOSSTDerivedOK(ACTXT_CAST pctxt, itemType,
15374 xmlSchemaPCustomErrExt(pctxt,
15412 xmlSchemaPIllegalFacetListUnionErr(pctxt,
15444 xmlSchemaTypeFixup(member->type, ACTXT_CAST pctxt);
15448 xmlSchemaPCustomErr(pctxt,
15471 xmlSchemaPCustomErr(pctxt,
15485 xmlSchemaPCustomErr(pctxt,
15497 xmlSchemaPCustomErr(pctxt,
15510 xmlSchemaPCustomErr(pctxt,
15551 (xmlSchemaCheckCOSSTDerivedOK(ACTXT_CAST pctxt,
15555 xmlSchemaPCustomErrExt(pctxt,
15586 xmlSchemaPIllegalFacetListUnionErr(pctxt,
15690 * @pctxt: the schema parser context
15705 xmlSchemaParseCheckCOSValidDefault(xmlSchemaParserCtxtPtr pctxt,
15732 xmlSchemaPCustomErr(pctxt,
15753 ret = xmlSchemaVCheckCVCSimpleType(ACTXT_CAST pctxt, node,
15756 ret = xmlSchemaVCheckCVCSimpleType(ACTXT_CAST pctxt, node,
15783 xmlSchemaCheckCTPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
15801 xmlSchemaCustomErr(ACTXT_CAST pctxt,
15847 xmlSchemaCustomErr(ACTXT_CAST pctxt,
15876 xmlSchemaCustomErr(ACTXT_CAST pctxt,
16132 xmlSchemaCustomErr(ACTXT_CAST pctxt,
16145 xmlSchemaCustomErr(ACTXT_CAST pctxt,
17054 xmlSchemaPCustomErrExt(pctxt, \
17063 xmlSchemaPCustomErr(pctxt, \
17069 xmlSchemaPCustomErr(pctxt, \
17076 xmlSchemaDeriveFacetErr(xmlSchemaParserCtxtPtr pctxt,
17104 xmlSchemaPCustomErr(pctxt,
17120 xmlSchemaDeriveAndValidateFacets(xmlSchemaParserCtxtPtr pctxt,
17251 xmlSchemaDeriveFacetErr(pctxt, flength, bflength, 0, 0, 1);
17266 xmlSchemaDeriveFacetErr(pctxt, fminlen, bfminlen, 1, 1, 1);
17280 xmlSchemaDeriveFacetErr(pctxt, fmaxlen, bfmaxlen, -1, 1, 1);
17299 xmlSchemaDeriveFacetErr(pctxt, flength, fminlen, 1, 1, 0);
17309 xmlSchemaDeriveFacetErr(pctxt, flength, fmaxlen, -1, 1, 0);
17322 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, fmininc, 1, 1, 0);
17334 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfmaxinc, -1, 1, 1);
17345 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfmaxexc, -1, 0, 1);
17354 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfmininc, 1, 1, 1);
17363 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfminexc, 1, 0, 1);
17376 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, fminexc, 1, 1, 0);
17388 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfmaxexc, -1, 1, 1);
17400 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfmaxinc, -1, 1, 1);
17409 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfmininc, 1, 0, 1);
17418 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfminexc, 1, 0, 1);
17431 xmlSchemaDeriveFacetErr(pctxt, fminexc, fmaxinc, -1, 0, 0);
17443 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfminexc, 1, 1, 1);
17455 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfmaxinc, -1, 1, 1);
17464 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfmininc, 1, 1, 1);
17473 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfmaxexc, -1, 0, 1);
17486 xmlSchemaDeriveFacetErr(pctxt, fmininc, fmaxexc, -1, 0, 0);
17498 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfmininc, 1, 1, 1);
17510 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfmaxinc, -1, 1, 1);
17519 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfminexc, 1, 0, 1);
17527 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfmaxexc, -1, 0, 1);
17539 xmlSchemaDeriveFacetErr(pctxt, ftotdig, bftotdig,
17554 xmlSchemaDeriveFacetErr(pctxt, ffracdig, bffracdig,
17572 xmlSchemaDeriveFacetErr(pctxt, ffracdig, ftotdig,
17636 xmlSchemaPErrMemory(pctxt,
17659 xmlSchemaFinishMemberTypeDefinitionsProperty(xmlSchemaParserCtxtPtr pctxt,
17676 xmlSchemaTypeFixup(link->type, ACTXT_CAST pctxt);
17690 xmlSchemaPErrMemory(pctxt, "allocating a type link",
17828 xmlSchemaFixupSimpleTypeStageOne(xmlSchemaParserCtxtPtr pctxt,
17871 if (xmlSchemaFixupSimpleTypeStageOne(pctxt, type->baseType) == -1)
17900 xmlSchemaDebugFixedType(xmlSchemaParserCtxtPtr pctxt,
17955 xmlSchemaFixupSimpleTypeStageTwo(xmlSchemaParserCtxtPtr pctxt,
17958 int res, olderrs = pctxt->nberrors;
17975 xmlSchemaTypeFixup(type->baseType, ACTXT_CAST pctxt);
17983 (xmlSchemaFinishMemberTypeDefinitionsProperty(pctxt, type) == -1))
17995 res = xmlSchemaCheckSTPropsCorrect(pctxt, type);
18001 res = xmlSchemaCheckCOSSTRestricts(pctxt, type);
18018 res = xmlSchemaCheckFacetValues(type, pctxt);
18022 res = xmlSchemaDeriveAndValidateFacets(pctxt, type);
18034 xmlSchemaDebugFixedType(pctxt, type);
18036 if (olderrs != pctxt->nberrors)
18037 return(pctxt->err);
18042 xmlSchemaDebugFixedType(pctxt, type);
18048 xmlSchemaFixupComplexType(xmlSchemaParserCtxtPtr pctxt,
18051 int res = 0, olderrs = pctxt->nberrors;
18066 xmlSchemaTypeFixup(baseType, ACTXT_CAST pctxt);
18077 res = xmlSchemaCheckSRCCT(pctxt, type);
18126 snprintf(buf, 29, "#scST%d", ++(pctxt->counter));
18127 tmpname = xmlDictLookup(pctxt->dict, BAD_CAST buf, -1);
18128 content = xmlSchemaAddType(pctxt, pctxt->schema,
18132 content = xmlSchemaAddType(pctxt, pctxt->schema,
18155 xmlSchemaTypeFixup(contentBase, ACTXT_CAST pctxt);
18160 res = xmlSchemaFixupSimpleTypeStageOne(pctxt, content);
18162 res = xmlSchemaFixupSimpleTypeStageTwo(pctxt, content);
18178 xmlSchemaPCustomErr(pctxt,
18198 pctxt,
18218 xmlSchemaPCustomErr(pctxt,
18262 particle = xmlSchemaAddParticle(pctxt,
18270 xmlSchemaAddModelGroup(pctxt, pctxt->schema,
18349 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18369 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18387 particle = xmlSchemaAddParticle(pctxt,
18395 xmlSchemaAddModelGroup(pctxt, pctxt->schema,
18407 (xmlSchemaTreeItemPtr) xmlSchemaAddParticle(pctxt,
18455 res = xmlSchemaFixupTypeAttributeUses(pctxt, type);
18462 res = xmlSchemaCheckCTComponent(pctxt, type);
18466 xmlSchemaDebugFixedType(pctxt, type);
18468 if (olderrs != pctxt->nberrors)
18469 return(pctxt->err);
18476 xmlSchemaDebugFixedType(pctxt, type);
18478 return(pctxt->err);
18483 xmlSchemaDebugFixedType(pctxt, type);
18521 * @pctxt: the schema parser context or NULL
18532 xmlSchemaParserCtxtPtr pctxt,
18543 if (pctxt == NULL)
18592 pctxt = xmlSchemaNewParserCtxt("*");
18593 if (pctxt == NULL)
18604 ACTXT_CAST pctxt, facet->node, base,
18610 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18624 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18649 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18685 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
18710 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18721 if ((! ctxtGiven) && (pctxt != NULL))
18722 xmlSchemaFreeParserCtxt(pctxt);
18725 if ((! ctxtGiven) && (pctxt != NULL))
18726 xmlSchemaFreeParserCtxt(pctxt);
18739 xmlSchemaParserCtxtPtr pctxt)
18741 int res, olderrs = pctxt->nberrors;
18754 if (pctxt->vctxt == NULL) {
18755 if (xmlSchemaCreateVCtxtOnPCtxt(pctxt) == -1)
18758 pctxt->vctxt->schema = pctxt->schema;
18760 res = xmlSchemaCheckFacet(facet, typeDecl, pctxt, name);
18764 pctxt->vctxt->schema = NULL;
18766 if (olderrs != pctxt->nberrors)
18767 return(pctxt->err);
19040 xmlSchemaAttributeGroupExpandRefs(xmlSchemaParserCtxtPtr pctxt,
19045 * @pctxt: the parser context
19058 xmlSchemaExpandAttributeGroupRefs(xmlSchemaParserCtxtPtr pctxt,
19110 if (xmlSchemaAttributeGroupExpandRefs(pctxt, gr) == -1)
19132 tmpWild = xmlSchemaAddWildcard(pctxt, pctxt->schema,
19137 if (xmlSchemaCloneWildcardNsConstraints(pctxt,
19145 if (xmlSchemaIntersectWildcards(pctxt, *completeWild,
19192 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
19217 * @pctxt: the parser context
19228 xmlSchemaAttributeGroupExpandRefs(xmlSchemaParserCtxtPtr pctxt,
19236 if (xmlSchemaExpandAttributeGroupRefs(pctxt, WXS_BASIC_CAST attrGr,
19244 * @pctxt: the parser context
19254 xmlSchemaCheckAGPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
19290 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19320 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19388 xmlSchemaCheckAttrPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
19414 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19420 return(pctxt->err);
19430 ret = xmlSchemaVCheckCVCSimpleType(ACTXT_CAST pctxt,
19440 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19445 return(pctxt->err);
19486 xmlSchemaCheckElemPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
19500 xmlSchemaCheckElementDeclComponent(head, pctxt);
19506 xmlSchemaPCustomErr(pctxt,
19528 xmlSchemaPCustomErrExt(pctxt,
19563 if (xmlSchemaCheckCOSDerivedOK(ACTXT_CAST pctxt, typeDef,
19568 xmlSchemaPCustomErrExt(pctxt,
19600 xmlSchemaPCustomErr(pctxt,
19617 xmlSchemaPErr(pctxt, elemDecl->node,
19632 vcret = xmlSchemaParseCheckCOSValidDefault(pctxt, node,
19769 * @pctxt: the schema parser context
19777 xmlSchemaCheckElementDeclConsistent(xmlSchemaParserCtxtPtr pctxt,
19804 ret = xmlSchemaCheckElementDeclConsistent(pctxt,
19828 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19855 ret = xmlSchemaCheckElementDeclConsistent(pctxt, ctxtComponent,
19869 xmlSchemaInternalErr2(ACTXT_CAST pctxt,
20265 xmlSchemaParserCtxtPtr pctxt)
20271 xmlSchemaGetIDC(pctxt->schema, idc->ref->name,
20278 xmlSchemaPResCompAttrErr(pctxt,
20284 return(pctxt->err);
20289 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20295 return(pctxt->err);
20309 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20318 return(pctxt->err);
20327 xmlSchemaParserCtxtPtr pctxt)
20329 if (xmlSchemaGetAttributeDecl(pctxt->schema, prohib->name,
20332 xmlSchemaPResCompAttrErr(pctxt,
20352 xmlSchemaCheckSRCRedefineFirst(xmlSchemaParserCtxtPtr pctxt)
20355 xmlSchemaRedefPtr redef = WXS_CONSTRUCTOR(pctxt)->redefs;
20403 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20416 err = pctxt->err;
20507 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20516 err = pctxt->err;
20527 xmlSchemaCheckSRCRedefineSecond(xmlSchemaParserCtxtPtr pctxt)
20530 xmlSchemaRedefPtr redef = WXS_CONSTRUCTOR(pctxt)->redefs;
20583 err = xmlSchemaCheckDerivationOKRestriction2to4(pctxt,
20603 xmlSchemaAddComponents(xmlSchemaParserCtxtPtr pctxt,
20683 *table = xmlHashCreateDict(10, pctxt->dict);
20694 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20712 if (xmlSchemaAddComponents(pctxt, rel->bucket) == -1)
20722 xmlSchemaFixupComponents(xmlSchemaParserCtxtPtr pctxt,
20725 xmlSchemaConstructionCtxtPtr con = pctxt->constructor;
20731 #define FIXHFAILURE if (pctxt->err == XML_SCHEMAP_INTERNAL) goto exit_failure;
20758 xmlSchemaCheckSRCRedefineFirst(pctxt);
20763 xmlSchemaAddComponents(pctxt, rootBucket);
20765 pctxt->ctxtType = NULL;
20799 (xmlSchemaElementPtr) item, pctxt);
20805 (xmlSchemaTypePtr) item, pctxt);
20810 (xmlSchemaAttributePtr) item, pctxt);
20815 (xmlSchemaAttributeUsePtr) item, pctxt);
20823 WXS_QNAME_CAST item, pctxt);
20830 xmlSchemaResolveModelGroupParticleReferences(pctxt,
20838 (xmlSchemaIDCPtr) item, pctxt);
20847 WXS_ATTR_PROHIB_CAST item, pctxt);
20854 if (pctxt->nberrors != 0)
20874 (xmlSchemaTypePtr) item, pctxt);
20876 if (pctxt->nberrors != 0)
20881 (xmlSchemaModelGroupDefPtr) item, pctxt);
20883 if (pctxt->nberrors != 0)
20888 (xmlSchemaAttributeGroupPtr) item, pctxt);
20890 if (pctxt->nberrors != 0)
20897 if (pctxt->nberrors != 0)
20912 xmlSchemaModelGroupToModelGroupDefFixup(pctxt,
20919 if (pctxt->nberrors != 0)
20931 xmlSchemaAttributeGroupExpandRefs(pctxt,
20940 if (pctxt->nberrors != 0)
20952 xmlSchemaFixupSimpleTypeStageOne(pctxt,
20961 if (pctxt->nberrors != 0)
20972 xmlSchemaCheckUnionTypeDefCircular(pctxt,
20981 if (pctxt->nberrors != 0)
20992 xmlSchemaFixupSimpleTypeStageTwo(pctxt, WXS_TYPE_CAST item);
21000 if (pctxt->nberrors != 0)
21012 xmlSchemaCheckAttrPropsCorrect(pctxt, WXS_ATTR_CAST item);
21019 if (pctxt->nberrors != 0)
21029 xmlSchemaCheckAttrUsePropsCorrect(pctxt,
21038 if (pctxt->nberrors != 0)
21051 xmlSchemaCheckAGPropsCorrect(pctxt, WXS_ATTR_GROUP_CAST item);
21059 if (pctxt->nberrors != 0)
21065 if (WXS_CONSTRUCTOR(pctxt)->redefs != NULL)
21066 xmlSchemaCheckSRCRedefineSecond(pctxt);
21067 if (pctxt->nberrors != 0)
21078 xmlSchemaFixupComplexType(pctxt, WXS_TYPE_CAST item);
21086 if (pctxt->nberrors != 0)
21108 (xmlSchemaElementPtr) elemDecl, pctxt);
21121 xmlSchemaCheckElementDeclConsistent(pctxt,
21132 if (pctxt->nberrors != 0)
21144 xmlSchemaBuildContentModel((xmlSchemaTypePtr) item, pctxt);
21151 if (pctxt->nberrors != 0)
21159 ret = pctxt->err;
21480 * @pctxt: a schema parser context
21500 xmlSchemaParserCtxtPtr pctxt;
21506 if (vctxt->pctxt == NULL) {
21511 pctxt = vctxt->pctxt;
21512 if (pctxt->constructor == NULL) {
21520 location = xmlSchemaBuildAbsoluteURI(pctxt->dict,
21527 ret = xmlSchemaAddSchemaDoc(pctxt, XML_SCHEMA_SCHEMA_IMPORT,
21547 (WXS_CONSTRUCTOR(pctxt)->bucket == NULL))
21548 WXS_CONSTRUCTOR(pctxt)->bucket = bucket;
21559 pctxt->nberrors = 0;
21560 pctxt->err = 0;
21561 pctxt->doc = bucket->doc;
21563 ret = xmlSchemaParseNewDocWithContext(pctxt, schema, bucket);
21565 pctxt->doc = NULL;
21569 if ((ret == 0) && (pctxt->nberrors != 0))
21570 ret = pctxt->err;
21571 if (pctxt->nberrors == 0) {
21578 xmlSchemaFixupComponents(pctxt, bucket);
21579 ret = pctxt->err;
21586 vctxt->nberrors += pctxt->nberrors;
21589 vctxt->nberrors += pctxt->nberrors;
21591 pctxt->doc = NULL;
21594 pctxt->doc = NULL;
24863 * if ((vctxt->pctxt == NULL) &&
27492 if (ctxt->pctxt != NULL)
27493 xmlSchemaFreeParserCtxt(ctxt->pctxt);
27601 if (ctxt->pctxt != NULL)
27602 xmlSchemaSetParserErrors(ctxt->pctxt, err, warn, ctx);
27623 if (ctxt->pctxt != NULL)
27624 xmlSchemaSetParserStructuredErrors(ctxt->pctxt, serror, ctx);
27890 xmlSchemaParserCtxtPtr pctxt;
27899 if ((vctxt->pctxt == NULL) &&
27902 pctxt = vctxt->pctxt;
27903 pctxt->xsiAssemble = 1;
27907 vctxt->schema = xmlSchemaNewSchema(pctxt);
27913 pctxt->constructor = xmlSchemaConstructionCtxtCreate(pctxt->dict);
27914 if (pctxt->constructor == NULL)
27916 pctxt->constructor->mainSchema = vctxt->schema;
27920 pctxt->ownsConstructor = 1;
28577 xmlParserCtxtPtr pctxt = NULL;
28587 pctxt = xmlNewParserCtxt();
28588 if (pctxt == NULL)
28590 old_sax = pctxt->sax;
28591 pctxt->sax = sax;
28592 pctxt->userData = user_data;
28595 xmlCtxtUseOptions(pctxt, options);
28597 pctxt->linenumbers = 1;
28599 inputStream = xmlNewIOInputStream(pctxt, input, enc);;
28604 inputPush(pctxt, inputStream);
28605 ctxt->parserCtxt = pctxt;
28611 plug = xmlSchemaSAXPlug(ctxt, &(pctxt->sax), &(pctxt->userData));
28618 ctxt->sax = pctxt->sax;
28636 if (pctxt != NULL) {
28637 pctxt->sax = old_sax;
28638 xmlFreeParserCtxt(pctxt);