Home | History | Annotate | Download | only in libxml2

Lines Matching defs:pctxt

993     xmlSchemaParserCtxtPtr pctxt;
1100 xmlSchemaParseAttributeGroupRef(xmlSchemaParserCtxtPtr pctxt,
2112 xmlSchemaParserCtxtPtr pctxt = (xmlSchemaParserCtxtPtr) ctxt;
2114 pctxt->nberrors++;
2115 pctxt->err = error;
2116 channel = pctxt->error;
2118 channel = pctxt->warning;
2120 schannel = pctxt->serror;
2121 data = pctxt->errCtxt;
2310 xmlSchemaPInternalErr(xmlSchemaParserCtxtPtr pctxt,
2316 xmlSchemaInternalErr2(ACTXT_CAST pctxt, funcName, message,
2765 #define PERROR_INT(func, msg) xmlSchemaInternalErr(ACTXT_CAST pctxt, func, msg);
3560 xmlSchemaBucketCreate(xmlSchemaParserCtxtPtr pctxt,
3567 if (WXS_CONSTRUCTOR(pctxt)->mainSchema == NULL) {
3572 mainSchema = WXS_CONSTRUCTOR(pctxt)->mainSchema;
3603 if (! WXS_HAS_BUCKETS(pctxt)) {
3613 WXS_CONSTRUCTOR(pctxt)->mainBucket = ret;
3630 WXS_IMPBUCKET(ret)->schema = xmlSchemaNewSchema(pctxt);
3647 WXS_CONSTRUCTOR(pctxt)->dict);
3667 if (WXS_IS_BUCKET_IMPMAIN(WXS_CONSTRUCTOR(pctxt)->bucket->type))
3669 WXS_IMPBUCKET(WXS_CONSTRUCTOR(pctxt)->bucket);
3672 WXS_INCBUCKET(WXS_CONSTRUCTOR(pctxt)->bucket)->ownerImport;
3688 if (xmlSchemaItemListAdd(WXS_CONSTRUCTOR(pctxt)->buckets, ret) == -1)
5218 xmlSchemaAddAttributeUse(xmlSchemaParserCtxtPtr pctxt,
5223 if (pctxt == NULL)
5228 xmlSchemaPErrMemory(pctxt, "allocating attribute", NULL);
5235 WXS_ADD_LOCAL(pctxt, ret);
5246 xmlSchemaAddRedef(xmlSchemaParserCtxtPtr pctxt,
5257 xmlSchemaPErrMemory(pctxt,
5266 if (WXS_CONSTRUCTOR(pctxt)->redefs == NULL)
5267 WXS_CONSTRUCTOR(pctxt)->redefs = ret;
5269 WXS_CONSTRUCTOR(pctxt)->lastRedef->next = ret;
5270 WXS_CONSTRUCTOR(pctxt)->lastRedef = ret;
5288 xmlSchemaAddAttributeGroupDefinition(xmlSchemaParserCtxtPtr pctxt,
5296 if ((pctxt == NULL) || (name == NULL))
5302 xmlSchemaPErrMemory(pctxt, "allocating attribute group", NULL);
5313 if (pctxt->isRedefine) {
5314 pctxt->redef = xmlSchemaAddRedef(pctxt, pctxt->redefined,
5316 if (pctxt->redef == NULL) {
5320 pctxt->redefCounter = 0;
5322 WXS_ADD_GLOBAL(pctxt, ret);
5323 WXS_ADD_PENDING(pctxt, ret);
5419 xmlSchemaNewQNameRef(xmlSchemaParserCtxtPtr pctxt,
5429 xmlSchemaPErrMemory(pctxt,
5442 WXS_ADD_LOCAL(pctxt, ret);
5447 xmlSchemaAddAttributeUseProhib(xmlSchemaParserCtxtPtr pctxt)
5454 xmlSchemaPErrMemory(pctxt,
5460 WXS_ADD_LOCAL(pctxt, ret);
5701 xmlSchemaSubstGroupAdd(xmlSchemaParserCtxtPtr pctxt,
5707 if (WXS_SUBST_GROUPS(pctxt) == NULL) {
5708 WXS_SUBST_GROUPS(pctxt) = xmlHashCreateDict(10, pctxt->dict);
5709 if (WXS_SUBST_GROUPS(pctxt) == NULL)
5728 if (xmlHashAddEntry2(WXS_SUBST_GROUPS(pctxt),
5739 xmlSchemaSubstGroupGet(xmlSchemaParserCtxtPtr pctxt,
5742 if (WXS_SUBST_GROUPS(pctxt) == NULL)
5744 return(xmlHashLookup2(WXS_SUBST_GROUPS(pctxt),
5751 * @pctxt: a schema parser context
5760 xmlSchemaAddElementSubstitutionMember(xmlSchemaParserCtxtPtr pctxt,
5766 if ((pctxt == NULL) || (head == NULL) || (member == NULL))
5769 substGroup = xmlSchemaSubstGroupGet(pctxt, head);
5771 substGroup = xmlSchemaSubstGroupAdd(pctxt, head);
6247 xmlSchemaParseLocalAttribute(xmlSchemaParserCtxtPtr pctxt,
6277 xmlSchemaPValAttrNodeValue(xmlSchemaParserCtxtPtr pctxt,
6290 if ((pctxt == NULL) || (type == NULL) || (attr == NULL))
6325 xmlSchemaPSimpleTypeErr(pctxt,
6424 xmlSchemaCheckReference(xmlSchemaParserCtxtPtr pctxt,
6431 if (xmlStrEqual(pctxt->targetNamespace, namespaceName))
6438 if (WXS_BUCKET(pctxt)->relations != NULL) {
6441 rel = WXS_BUCKET(pctxt)->relations;
6456 xmlSchemaCustomErr(ACTXT_CAST pctxt,
6462 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7115 xmlSchemaParseLocalAttribute(xmlSchemaParserCtxtPtr pctxt,
7136 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7140 if (xmlSchemaPValAttrNodeQName(pctxt, schema,
7144 if (xmlSchemaCheckReference(pctxt, schema, node, attr, tmpNs) != 0)
7148 nberrors = pctxt->nberrors;
7157 xmlSchemaPValAttrNodeID(pctxt, attr);
7166 xmlSchemaPValAttrNodeID(pctxt, attr);
7169 xmlSchemaPValAttrNodeQName(pctxt, schema, NULL,
7177 attrValue = xmlSchemaGetNodeContent(pctxt,
7180 ns = pctxt->targetNamespace;
7183 xmlSchemaPSimpleTypeErr(pctxt,
7194 attrValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7203 xmlSchemaPSimpleTypeErr(pctxt,
7216 xmlSchemaPMutualExclAttrErr(pctxt,
7220 defValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7230 xmlSchemaPMutualExclAttrErr(pctxt,
7234 defValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7242 xmlSchemaPIllegalAttrErr(pctxt,
7255 xmlSchemaPSimpleTypeErr(pctxt,
7266 if (nberrors != pctxt->nberrors)
7273 ns = pctxt->targetNamespace;
7279 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7287 xmlSchemaPMissingAttrErr(pctxt, XML_SCHEMAP_S4S_ATTR_MISSING,
7291 if (xmlSchemaPValAttrNode(pctxt, NULL, attr,
7300 xmlSchemaPSimpleTypeErr(pctxt,
7313 use = xmlSchemaAddAttributeUse(pctxt, node);
7320 attrDecl = xmlSchemaAddAttribute(pctxt, schema, name, ns, node, 0);
7342 use = xmlSchemaAddAttributeUse(pctxt, node);
7348 WXS_ADD_PENDING(pctxt, use);
7353 ref = xmlSchemaNewQNameRef(pctxt, XML_SCHEMA_TYPE_ATTRIBUTE,
7380 xmlSchemaParseAnnotation(pctxt, child, 0);
7384 xmlSchemaPContentErr(pctxt,
7393 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
7401 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
7427 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
7441 prohib = xmlSchemaAddAttributeUseProhib(pctxt);
7451 WXS_ADD_PENDING(pctxt, prohib);
7459 use->annot = xmlSchemaParseAnnotation(pctxt, child, 1);
7470 xmlSchemaPContentErr(pctxt,
7475 xmlSchemaPContentErr(pctxt,
7487 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_SRC_ATTRIBUTE_4,
7493 xmlSchemaParseSimpleType(pctxt, schema, child, 0);
7497 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_S4S_ELEM_NOT_ALLOWED,
7507 xmlSchemaParseGlobalAttribute(xmlSchemaParserCtxtPtr pctxt,
7522 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7530 xmlSchemaPMissingAttrErr(pctxt, XML_SCHEMAP_S4S_ATTR_MISSING,
7534 if (xmlSchemaPValAttrNode(pctxt, NULL, attr,
7543 xmlSchemaPSimpleTypeErr(pctxt,
7557 if (xmlStrEqual(pctxt->targetNamespace, xmlSchemaInstanceNs)) {
7558 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7564 ret = xmlSchemaAddAttribute(pctxt, schema, attrValue,
7565 pctxt->targetNamespace, node, 1);
7582 xmlSchemaPIllegalAttrErr(pctxt,
7586 xmlSchemaPIllegalAttrErr(pctxt,
7591 xmlSchemaPValAttrQName(pctxt, schema, NULL,
7594 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
7598 ret->defValue = xmlSchemaGetProp(pctxt, node, "fixed");
7611 xmlSchemaPMutualExclAttrErr(pctxt, XML_SCHEMAP_SRC_ATTRIBUTE_1,
7614 ret->defValue = xmlSchemaGetNodeContent(pctxt, (xmlNodePtr) attr);
7621 ret->annot = xmlSchemaParseAnnotation(pctxt, child, 1);
7630 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_SRC_ATTRIBUTE_4,
7635 ret->subtypes = xmlSchemaParseSimpleType(pctxt, schema, child, 0);
7639 xmlSchemaPContentErr(pctxt, XML_SCHEMAP_S4S_ELEM_NOT_ALLOWED,
7660 xmlSchemaParseAttributeGroupRef(xmlSchemaParserCtxtPtr pctxt,
7669 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7674 xmlSchemaPMissingAttrErr(pctxt,
7679 xmlSchemaPValAttrNodeQName(pctxt, schema,
7681 if (xmlSchemaCheckReference(pctxt, schema, node, attr, refNs) != 0)
7693 xmlSchemaPIllegalAttrErr(pctxt,
7697 xmlSchemaPIllegalAttrErr(pctxt,
7703 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
7713 xmlSchemaParseAnnotation(pctxt, child, 0);
7717 xmlSchemaPContentErr(pctxt,
7726 if (pctxt->isRedefine && pctxt->redef &&
7727 (pctxt->redef->item->type ==
7729 (ref == pctxt->redef->refName) &&
7730 (refNs == pctxt->redef->refTargetNs))
7739 if (pctxt->redefCounter != 0) {
7742 xmlSchemaCustomErr(ACTXT_CAST pctxt,
7751 pctxt->redefCounter++;
7756 ret = xmlSchemaNewQNameRef(pctxt,
7761 pctxt->redef->reference = WXS_BASIC_CAST ret;
7768 ret = xmlSchemaNewQNameRef(pctxt,
7774 WXS_ADD_PENDING(pctxt, ret);
7781 * @pctxt: a schema validation context
7791 xmlSchemaParseAttributeGroupDefinition(xmlSchemaParserCtxtPtr pctxt,
7801 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
7806 xmlSchemaPMissingAttrErr(pctxt,
7814 if (xmlSchemaPValAttrNode(pctxt,
7819 ret = xmlSchemaAddAttributeGroupDefinition(pctxt, schema,
7820 name, pctxt->targetNamespace, node);
7832 xmlSchemaPIllegalAttrErr(pctxt,
7836 xmlSchemaPIllegalAttrErr(pctxt,
7842 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
7848 ret->annot = xmlSchemaParseAnnotation(pctxt, child, 1);
7854 if (xmlSchemaParseLocalAttributes(pctxt, schema, &child,
7864 ret->attributeWildcard = xmlSchemaParseAnyAttribute(pctxt,
7869 xmlSchemaPContentErr(pctxt,
10003 if (vctxt->pctxt == NULL) {
10005 vctxt->pctxt =
10008 vctxt->pctxt = xmlSchemaNewParserCtxt("*");
10009 if (vctxt->pctxt == NULL) {
10015 xmlSchemaSetParserErrors(vctxt->pctxt, vctxt->error,
10017 xmlSchemaSetParserStructuredErrors(vctxt->pctxt, vctxt->serror,
10025 * @pctxt: the schema parser context
10034 xmlSchemaGetSchemaBucket(xmlSchemaParserCtxtPtr pctxt,
10040 list = pctxt->constructor->buckets;
10056 xmlSchemaGetChameleonSchemaBucket(xmlSchemaParserCtxtPtr pctxt,
10063 list = pctxt->constructor->buckets;
10085 xmlSchemaGetSchemaBucketByTNS(xmlSchemaParserCtxtPtr pctxt,
10092 list = pctxt->constructor->buckets;
10110 xmlSchemaParseNewDocWithContext(xmlSchemaParserCtxtPtr pctxt,
10118 xmlSchemaBucketPtr oldbucket = pctxt->constructor->bucket;
10131 pctxt->schema = schema;
10136 pctxt->targetNamespace = bucket->targetNamespace;
10137 WXS_CONSTRUCTOR(pctxt)->bucket = bucket;
10144 pctxt->isS4S = 1;
10150 ret = xmlSchemaParseSchemaElement(pctxt, schema, node);
10156 oldErrs = pctxt->nberrors;
10157 ret = xmlSchemaParseSchemaTopLevel(pctxt, schema, node->children);
10162 * as a result of the obove functions; so better rely on pctxt->err
10165 if ((ret == 0) && (oldErrs != pctxt->nberrors)) {
10166 ret = pctxt->err;
10171 WXS_CONSTRUCTOR(pctxt)->bucket = oldbucket;
10179 xmlSchemaParseNewDoc(xmlSchemaParserCtxtPtr pctxt,
10198 if (pctxt->constructor == NULL) {
10205 (const char *) bucket->schemaLocation, pctxt->dict);
10208 newpctxt->constructor = pctxt->constructor;
10215 xmlSchemaSetParserErrors(newpctxt, pctxt->error, pctxt->warning,
10216 pctxt->errCtxt);
10217 xmlSchemaSetParserStructuredErrors(newpctxt, pctxt->serror,
10218 pctxt->errCtxt);
10219 newpctxt->counter = pctxt->counter;
10226 pctxt->err = res;
10227 pctxt->nberrors += newpctxt->nberrors;
10228 pctxt->counter = newpctxt->counter;
10286 * @pctxt: a schema validation context
10297 xmlSchemaAddSchemaDoc(xmlSchemaParserCtxtPtr pctxt,
10335 if ((type == XML_SCHEMA_SCHEMA_MAIN) || (! WXS_HAS_BUCKETS(pctxt)))
10340 bkt = xmlSchemaGetSchemaBucket(pctxt, schemaLocation);
10342 (pctxt->constructor->bucket == bkt)) {
10345 xmlSchemaCustomErr(ACTXT_CAST pctxt, err,
10358 xmlSchemaSchemaRelationAddChild(pctxt->constructor->bucket,
10389 xmlSchemaCustomErr(ACTXT_CAST pctxt, err,
10406 xmlSchemaCustomErr(ACTXT_CAST pctxt, err,
10441 bkt = xmlSchemaGetSchemaBucketByTNS(pctxt,
10460 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
10500 chamel = xmlSchemaGetChameleonSchemaBucket(pctxt,
10538 schemaLocation = xmlDictLookup(pctxt->dict,
10551 if ((pctxt->dict != NULL) && (parserCtxt->dict != NULL)) {
10557 parserCtxt->dict = pctxt->dict;
10601 xmlSchemaCustomErr(ACTXT_CAST pctxt, res,
10611 xmlSchemaPErr(pctxt, NULL,
10627 xmlSchemaCustomErr(ACTXT_CAST pctxt, XML_SCHEMAP_NOROOT,
10636 xmlSchemaCleanupDoc(pctxt, docElem);
10641 xmlSchemaCustomErr(ACTXT_CAST pctxt, XML_SCHEMAP_NOT_SCHEMA,
10651 targetNamespace = xmlSchemaGetProp(pctxt, docElem,
10658 bkt = xmlSchemaBucketCreate(pctxt, type,
10697 return(pctxt->err);
10721 xmlSchemaParseImport(xmlSchemaParserCtxtPtr pctxt, xmlSchemaPtr schema,
10731 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
10743 xmlSchemaPIllegalAttrErr(pctxt,
10747 xmlSchemaPIllegalAttrErr(pctxt,
10755 if (xmlSchemaPValAttr(pctxt, NULL, node,
10758 xmlSchemaPSimpleTypeErr(pctxt,
10763 return (pctxt->err);
10766 if (xmlSchemaPValAttr(pctxt, NULL, node,
10769 xmlSchemaPSimpleTypeErr(pctxt,
10774 return (pctxt->err);
10788 xmlSchemaPContentErr(pctxt,
10801 thisTargetNamespace = WXS_BUCKET(pctxt)->origTargetNamespace;
10809 xmlSchemaPCustomErr(pctxt,
10815 return (pctxt->err);
10823 xmlSchemaPCustomErr(pctxt,
10829 return (pctxt->err);
10836 schemaLocation = xmlSchemaBuildAbsoluteURI(pctxt->dict,
10838 ret = xmlSchemaAddSchemaDoc(pctxt, XML_SCHEMA_SCHEMA_IMPORT,
10853 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
10861 ret = xmlSchemaParseNewDoc(pctxt, schema, bucket);
10868 xmlSchemaParseIncludeOrRedefineAttrs(xmlSchemaParserCtxtPtr pctxt,
10876 if ((pctxt == NULL) || (schema == NULL) || (node == NULL) ||
10890 xmlSchemaPIllegalAttrErr(pctxt,
10894 xmlSchemaPIllegalAttrErr(pctxt,
10899 xmlSchemaPValAttrID(pctxt, node, BAD_CAST "id");
10912 if (xmlSchemaPValAttrNode(pctxt, NULL, attr,
10928 (*schemaLocation) = (xmlChar *) xmlDictLookup(pctxt->dict, uri, -1);
10931 xmlSchemaPMissingAttrErr(pctxt,
10939 if (xmlStrEqual(*schemaLocation, pctxt->URL)) {
10941 xmlSchemaPCustomErr(pctxt,
10947 xmlSchemaPCustomErr(pctxt,
10958 return(pctxt->err);
10964 xmlSchemaParseIncludeOrRedefine(xmlSchemaParserCtxtPtr pctxt,
10975 if ((pctxt == NULL) || (schema == NULL) || (node == NULL))
10982 res = xmlSchemaParseIncludeOrRedefineAttrs(pctxt, schema,
10989 res = xmlSchemaAddSchemaDoc(pctxt, type, schemaLocation, NULL,
10990 NULL, 0, node, pctxt->targetNamespace, NULL, &bucket);
11012 xmlSchemaCustomErr(ACTXT_CAST pctxt, res,
11029 xmlSchemaCustomErr(ACTXT_CAST pctxt, res,
11047 if (pctxt->targetNamespace == NULL) {
11048 xmlSchemaCustomErr(ACTXT_CAST pctxt,
11057 pctxt->targetNamespace)) {
11059 xmlSchemaPCustomErrExt(pctxt,
11066 pctxt->targetNamespace);
11069 } else if (pctxt->targetNamespace != NULL) {
11077 xmlSchemaCustomErr(ACTXT_CAST pctxt,
11086 bucket->targetNamespace = pctxt->targetNamespace;
11100 xmlSchemaParseNewDoc(pctxt, schema, bucket);
11113 pctxt->redefined = bucket;
11117 pctxt->isRedefine = 1;
11128 xmlSchemaParseSimpleType(pctxt, schema, child, 1);
11130 xmlSchemaParseComplexType(pctxt, schema, child, 1);
11134 xmlSchemaParseModelGroupDefinition(pctxt,
11138 xmlSchemaParseAttributeGroupDefinition(pctxt, schema,
11143 pctxt->redefined = NULL;
11144 pctxt->isRedefine = 0;
11156 xmlSchemaPContentErr(pctxt, res,
11160 xmlSchemaPContentErr(pctxt, res,
11168 return(pctxt->err);
11172 xmlSchemaParseRedefine(xmlSchemaParserCtxtPtr pctxt, xmlSchemaPtr schema,
11180 res = xmlSchemaParseIncludeOrRedefine(pctxt, schema, node,
11188 xmlSchemaParseInclude(xmlSchemaParserCtxtPtr pctxt, xmlSchemaPtr schema,
11193 res = xmlSchemaParseIncludeOrRedefine(pctxt, schema, node,
12568 xmlSchemaBuildContentModelForSubstGroup(xmlSchemaParserCtxtPtr pctxt,
12581 start = pctxt->state;
12583 end = xmlAutomataNewState(pctxt->am);
12584 substGroup = xmlSchemaSubstGroupGet(pctxt, elemDecl);
12586 xmlSchemaPErr(pctxt, WXS_ITEM_NODE(particle),
12600 tmp = xmlAutomataNewCountedTrans(pctxt->am, start, NULL, counter);
12601 xmlAutomataNewTransition2(pctxt->am, tmp, end,
12608 xmlAutomataNewTransition2(pctxt->am, tmp, end,
12615 xmlAutomataNewEpsilon(pctxt->am,
12616 xmlAutomataNewTransition2(pctxt->am,
12633 * tmp = xmlAutomataNewOnceTrans2(pctxt->am, start, NULL,
12637 tmp = xmlAutomataNewTransition2(pctxt->am, start, NULL,
12639 xmlAutomataNewEpsilon(pctxt->am, tmp, end);
12648 xmlAutomataNewCounter(pctxt->am, minOccurs,
12650 hop = xmlAutomataNewState(pctxt->am);
12652 xmlAutomataNewEpsilon(pctxt->am,
12653 xmlAutomataNewTransition2(pctxt->am,
12662 xmlAutomataNewEpsilon(pctxt->am,
12663 xmlAutomataNewTransition2(pctxt->am,
12668 xmlAutomataNewCountedTrans(pctxt->am, hop, start, counter);
12669 xmlAutomataNewCounterTrans(pctxt->am, hop, end, counter);
12672 xmlAutomataNewEpsilon(pctxt->am, start, end);
12675 pctxt->state = end;
12750 xmlSchemaBuildAContentModel(xmlSchemaParserCtxtPtr pctxt,
12775 start = pctxt->state;
12776 end = xmlAutomataNewState(pctxt->am);
12785 pctxt->state =
12786 xmlAutomataNewTransition2(pctxt->am,
12788 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12792 pctxt->state =
12793 xmlAutomataNewTransition2(pctxt->am,
12795 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12800 pctxt->state = start;
12801 pctxt->state = xmlAutomataNewTransition2(pctxt->am,
12802 pctxt->state, NULL, BAD_CAST "*", ns->value, wild);
12803 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
12808 pctxt->state = xmlAutomataNewNegTrans(pctxt->am,
12821 counter = xmlAutomataNewCounter(pctxt->am, minOccurs, maxOccurs);
12822 hop = xmlAutomataNewState(pctxt->am);
12824 pctxt->state =
12825 xmlAutomataNewTransition2(pctxt->am,
12827 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12828 pctxt->state =
12829 xmlAutomataNewTransition2(pctxt->am,
12831 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12835 pctxt->state =
12836 xmlAutomataNewTransition2(pctxt->am,
12838 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
12843 pctxt->state = xmlAutomataNewNegTrans(pctxt->am,
12847 xmlAutomataNewCountedTrans(pctxt->am, hop, start, counter);
12848 xmlAutomataNewCounterTrans(pctxt->am, hop, end, counter);
12851 xmlAutomataNewEpsilon(pctxt->am, start, end);
12854 pctxt->state = end;
12858 ret = xmlSchemaBuildContentModelForElement(pctxt, particle);
12872 tmp2 = xmlSchemaBuildAContentModel(pctxt,
12878 xmlAutomataStatePtr oldstate = pctxt->state;
12885 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12887 oldstate = pctxt->state;
12889 counter = xmlAutomataNewCounter(pctxt->am,
12894 tmp2 = xmlSchemaBuildAContentModel(pctxt,
12899 tmp = pctxt->state;
12900 xmlAutomataNewCountedTrans(pctxt->am, tmp,
12902 pctxt->state =
12903 xmlAutomataNewCounterTrans(pctxt->am, tmp,
12906 xmlAutomataNewEpsilon(pctxt->am,
12907 oldstate, pctxt->state);
12910 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12912 oldstate = pctxt->state;
12916 tmp2 = xmlSchemaBuildAContentModel(pctxt,
12921 xmlAutomataNewEpsilon(pctxt->am, pctxt->state,
12928 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12929 pctxt->state, NULL);
12931 xmlAutomataNewEpsilon(pctxt->am,
12932 oldstate, pctxt->state);
12941 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12943 oldstate = pctxt->state;
12945 counter = xmlAutomataNewCounter(pctxt->am,
12951 tmp2 = xmlSchemaBuildAContentModel(pctxt,
12956 tmp = pctxt->state;
12957 xmlAutomataNewCountedTrans(pctxt->am,
12959 pctxt->state =
12960 xmlAutomataNewCounterTrans(pctxt->am, tmp, NULL,
12963 xmlAutomataNewEpsilon(pctxt->am,
12964 oldstate, pctxt->state);
12970 tmp2 = xmlSchemaBuildAContentModel(pctxt,
12981 pctxt->state = xmlAutomataNewEpsilon(pctxt->am,
12982 pctxt->state, NULL);
12985 xmlAutomataNewEpsilon(pctxt->am, oldstate,
12986 pctxt->state);
12998 start = pctxt->state;
12999 end = xmlAutomataNewState(pctxt->am);
13008 pctxt->state = start;
13009 tmp2 = xmlSchemaBuildAContentModel(pctxt,
13012 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, end);
13028 xmlAutomataNewCounter(pctxt->am, minOccurs, maxOccurs);
13029 hop = xmlAutomataNewState(pctxt->am);
13030 base = xmlAutomataNewState(pctxt->am);
13034 pctxt->state = base;
13035 tmp2 = xmlSchemaBuildAContentModel(pctxt,
13038 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, hop);
13041 xmlAutomataNewEpsilon(pctxt->am, start, base);
13042 xmlAutomataNewCountedTrans(pctxt->am, hop, base, counter);
13043 xmlAutomataNewCounterTrans(pctxt->am, hop, end, counter);
13045 xmlAutomataNewEpsilon(pctxt->am, base, end);
13048 xmlAutomataNewEpsilon(pctxt->am, start, end);
13051 pctxt->state = end;
13067 start = pctxt->state;
13068 tmp = xmlAutomataNewState(pctxt->am);
13069 xmlAutomataNewEpsilon(pctxt->am, pctxt->state, tmp);
13070 pctxt->state = tmp;
13072 pctxt->state = tmp;
13094 counter = xmlAutomataNewCounter(pctxt->am,
13096 xmlSchemaBuildContentModelForSubstGroup(pctxt,
13097 sub, counter, pctxt->state);
13101 xmlAutomataNewOnceTrans2(pctxt->am, pctxt->state,
13102 pctxt->state,
13109 xmlAutomataNewCountTrans2(pctxt->am, pctxt->state,
13110 pctxt->state,
13120 pctxt->state =
13121 xmlAutomataNewAllTrans(pctxt->am, pctxt->state, NULL, 0);
13123 xmlAutomataNewEpsilon(pctxt->am, start, pctxt->state);
13139 xmlSchemaInternalErr2(ACTXT_CAST pctxt,
14123 xmlSchemaCheckDerivationOKRestriction2to4(xmlSchemaParserCtxtPtr pctxt,
14167 xmlSchemaPAttrUseErr4(pctxt,
14177 /* err = pctxt->err; */
14178 } else if (xmlSchemaCheckCOSSTDerivedOK(ACTXT_CAST pctxt,
14190 xmlSchemaPAttrUseErr4(pctxt,
14207 /* err = pctxt->err; */
14241 xmlSchemaPAttrUseErr4(pctxt,
14252 /* err = pctxt->err; */
14274 xmlSchemaPAttrUseErr4(pctxt,
14283 /* err = pctxt->err; */
14317 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14345 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14355 return(pctxt->err);
14366 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14376 return(pctxt->err);
14388 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
14398 return(pctxt->err);
14406 xmlSchemaExpandAttributeGroupRefs(xmlSchemaParserCtxtPtr pctxt,
14426 xmlSchemaFixupTypeAttributeUses(xmlSchemaParserCtxtPtr pctxt,
14440 if (xmlSchemaTypeFixup(baseType, ACTXT_CAST pctxt) == -1)
14454 * into pctxt->attrProhibs.
14456 if (xmlSchemaExpandAttributeGroupRefs(pctxt,
14458 pctxt->attrProhibs) == -1)
14463 if (pctxt->attrProhibs->nbItems != 0)
14464 prohibs = pctxt->attrProhibs;
14466 if (xmlSchemaExpandAttributeGroupRefs(pctxt,
14579 if (xmlSchemaUnionWildcards(pctxt, type->attributeWildcard,
14904 * @pctxt: the schema parser context
14915 xmlSchemaCheckTypeDefCircularInternal(xmlSchemaParserCtxtPtr pctxt,
14925 xmlSchemaPCustomErr(pctxt,
14938 ret = xmlSchemaCheckTypeDefCircularInternal(pctxt, ctxtType,
14978 xmlSchemaCheckUnionTypeDefCircularRecur(xmlSchemaParserCtxtPtr pctxt,
14991 xmlSchemaPCustomErr(pctxt,
15002 res = xmlSchemaCheckUnionTypeDefCircularRecur(pctxt,
15017 xmlSchemaCheckUnionTypeDefCircular(xmlSchemaParserCtxtPtr pctxt,
15022 return(xmlSchemaCheckUnionTypeDefCircularRecur(pctxt, type,
15269 xmlSchemaCheckCOSSTRestricts(xmlSchemaParserCtxtPtr pctxt,
15287 xmlSchemaPCustomErr(pctxt,
15301 xmlSchemaPCustomErr(pctxt,
15329 xmlSchemaPIllegalFacetAtomicErr(pctxt,
15357 xmlSchemaTypeFixup(itemType, ACTXT_CAST pctxt);
15365 xmlSchemaPCustomErr(pctxt,
15378 xmlSchemaPCustomErr(pctxt,
15403 xmlSchemaPCustomErr(pctxt,
15421 xmlSchemaPIllegalFacetListUnionErr(pctxt,
15446 xmlSchemaPCustomErr(pctxt,
15460 xmlSchemaPCustomErr(pctxt,
15483 (xmlSchemaCheckCOSSTDerivedOK(ACTXT_CAST pctxt, itemType,
15486 xmlSchemaPCustomErrExt(pctxt,
15524 xmlSchemaPIllegalFacetListUnionErr(pctxt,
15556 xmlSchemaTypeFixup(member->type, ACTXT_CAST pctxt);
15560 xmlSchemaPCustomErr(pctxt,
15583 xmlSchemaPCustomErr(pctxt,
15597 xmlSchemaPCustomErr(pctxt,
15609 xmlSchemaPCustomErr(pctxt,
15622 xmlSchemaPCustomErr(pctxt,
15663 (xmlSchemaCheckCOSSTDerivedOK(ACTXT_CAST pctxt,
15667 xmlSchemaPCustomErrExt(pctxt,
15699 xmlSchemaPIllegalFacetListUnionErr(pctxt,
15803 * @pctxt: the schema parser context
15818 xmlSchemaParseCheckCOSValidDefault(xmlSchemaParserCtxtPtr pctxt,
15845 xmlSchemaPCustomErr(pctxt,
15866 ret = xmlSchemaVCheckCVCSimpleType(ACTXT_CAST pctxt, node,
15869 ret = xmlSchemaVCheckCVCSimpleType(ACTXT_CAST pctxt, node,
15896 xmlSchemaCheckCTPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
15914 xmlSchemaCustomErr(ACTXT_CAST pctxt,
15960 xmlSchemaCustomErr(ACTXT_CAST pctxt,
15989 xmlSchemaCustomErr(ACTXT_CAST pctxt,
16245 xmlSchemaCustomErr(ACTXT_CAST pctxt,
16258 xmlSchemaCustomErr(ACTXT_CAST pctxt,
17167 xmlSchemaPCustomErrExt(pctxt, \
17176 xmlSchemaPCustomErr(pctxt, \
17182 xmlSchemaPCustomErr(pctxt, \
17189 xmlSchemaDeriveFacetErr(xmlSchemaParserCtxtPtr pctxt,
17217 xmlSchemaPCustomErr(pctxt,
17233 xmlSchemaDeriveAndValidateFacets(xmlSchemaParserCtxtPtr pctxt,
17364 xmlSchemaDeriveFacetErr(pctxt, flength, bflength, 0, 0, 1);
17379 xmlSchemaDeriveFacetErr(pctxt, fminlen, bfminlen, 1, 1, 1);
17393 xmlSchemaDeriveFacetErr(pctxt, fmaxlen, bfmaxlen, -1, 1, 1);
17412 xmlSchemaDeriveFacetErr(pctxt, flength, fminlen, 1, 1, 0);
17422 xmlSchemaDeriveFacetErr(pctxt, flength, fmaxlen, -1, 1, 0);
17435 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, fmininc, 1, 1, 0);
17447 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfmaxinc, -1, 1, 1);
17458 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfmaxexc, -1, 0, 1);
17467 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfmininc, 1, 1, 1);
17476 xmlSchemaDeriveFacetErr(pctxt, fmaxinc, bfminexc, 1, 0, 1);
17489 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, fminexc, 1, 1, 0);
17501 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfmaxexc, -1, 1, 1);
17513 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfmaxinc, -1, 1, 1);
17522 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfmininc, 1, 0, 1);
17531 xmlSchemaDeriveFacetErr(pctxt, fmaxexc, bfminexc, 1, 0, 1);
17544 xmlSchemaDeriveFacetErr(pctxt, fminexc, fmaxinc, -1, 0, 0);
17556 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfminexc, 1, 1, 1);
17568 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfmaxinc, -1, 1, 1);
17577 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfmininc, 1, 1, 1);
17586 xmlSchemaDeriveFacetErr(pctxt, fminexc, bfmaxexc, -1, 0, 1);
17599 xmlSchemaDeriveFacetErr(pctxt, fmininc, fmaxexc, -1, 0, 0);
17611 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfmininc, 1, 1, 1);
17623 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfmaxinc, -1, 1, 1);
17632 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfminexc, 1, 0, 1);
17640 xmlSchemaDeriveFacetErr(pctxt, fmininc, bfmaxexc, -1, 0, 1);
17652 xmlSchemaDeriveFacetErr(pctxt, ftotdig, bftotdig,
17667 xmlSchemaDeriveFacetErr(pctxt, ffracdig, bffracdig,
17685 xmlSchemaDeriveFacetErr(pctxt, ffracdig, ftotdig,
17749 xmlSchemaPErrMemory(pctxt,
17772 xmlSchemaFinishMemberTypeDefinitionsProperty(xmlSchemaParserCtxtPtr pctxt,
17789 xmlSchemaTypeFixup(link->type, ACTXT_CAST pctxt);
17803 xmlSchemaPErrMemory(pctxt, "allocating a type link",
17941 xmlSchemaFixupSimpleTypeStageOne(xmlSchemaParserCtxtPtr pctxt,
17984 if (xmlSchemaFixupSimpleTypeStageOne(pctxt, type->baseType) == -1)
18013 xmlSchemaDebugFixedType(xmlSchemaParserCtxtPtr pctxt,
18068 xmlSchemaFixupSimpleTypeStageTwo(xmlSchemaParserCtxtPtr pctxt,
18071 int res, olderrs = pctxt->nberrors;
18088 xmlSchemaTypeFixup(type->baseType, ACTXT_CAST pctxt);
18096 (xmlSchemaFinishMemberTypeDefinitionsProperty(pctxt, type) == -1))
18108 res = xmlSchemaCheckSTPropsCorrect(pctxt, type);
18114 res = xmlSchemaCheckCOSSTRestricts(pctxt, type);
18131 res = xmlSchemaCheckFacetValues(type, pctxt);
18135 res = xmlSchemaDeriveAndValidateFacets(pctxt, type);
18147 xmlSchemaDebugFixedType(pctxt, type);
18149 pctxt->nberrors)
18150 return(pctxt->err);
18155 xmlSchemaDebugFixedType(pctxt, type);
18161 xmlSchemaFixupComplexType(xmlSchemaParserCtxtPtr pctxt,
18164 int res = 0, olderrs = pctxt->nberrors;
18179 xmlSchemaTypeFixup(baseType, ACTXT_CAST pctxt);
18190 res = xmlSchemaCheckSRCCT(pctxt, type);
18239 snprintf(buf, 29, "#scST%d", ++(pctxt->counter));
18240 tmpname = xmlDictLookup(pctxt->dict, BAD_CAST buf, -1);
18241 content = xmlSchemaAddType(pctxt, pctxt->schema,
18245 content = xmlSchemaAddType(pctxt, pctxt->schema,
18268 xmlSchemaTypeFixup(contentBase, ACTXT_CAST pctxt);
18273 res = xmlSchemaFixupSimpleTypeStageOne(pctxt, content);
18275 res = xmlSchemaFixupSimpleTypeStageTwo(pctxt, content);
18291 xmlSchemaPCustomErr(pctxt,
18311 xmlSchemaPCustomErr(pctxt,
18331 xmlSchemaPCustomErr(pctxt,
18375 particle = xmlSchemaAddParticle(pctxt,
18383 xmlSchemaAddModelGroup(pctxt, pctxt->schema,
18462 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18482 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18500 particle = xmlSchemaAddParticle(pctxt,
18508 xmlSchemaAddModelGroup(pctxt, pctxt->schema,
18520 (xmlSchemaTreeItemPtr) xmlSchemaAddParticle(pctxt,
18568 res = xmlSchemaFixupTypeAttributeUses(pctxt, type);
18575 res = xmlSchemaCheckCTComponent(pctxt, type);
18579 xmlSchemaDebugFixedType(pctxt, type);
18581 if (olderrs != pctxt->nberrors)
18582 return(pctxt->err);
18589 xmlSchemaDebugFixedType(pctxt, type);
18591 return(pctxt->err);
18596 xmlSchemaDebugFixedType(pctxt, type);
18634 * @pctxt: the schema parser context or NULL
18645 xmlSchemaParserCtxtPtr pctxt,
18656 if (pctxt == NULL)
18705 pctxt = xmlSchemaNewParserCtxt("*");
18706 if (pctxt == NULL)
18717 ACTXT_CAST pctxt, facet->node, base,
18723 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18737 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18762 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18798 xmlSchemaCustomErr4(ACTXT_CAST pctxt,
18823 xmlSchemaCustomErr(ACTXT_CAST pctxt,
18834 if ((! ctxtGiven) && (pctxt != NULL))
18835 xmlSchemaFreeParserCtxt(pctxt);
18838 if ((! ctxtGiven) && (pctxt != NULL))
18839 xmlSchemaFreeParserCtxt(pctxt);
18852 xmlSchemaParserCtxtPtr pctxt)
18854 int res, olderrs = pctxt->nberrors;
18867 if (pctxt->vctxt == NULL) {
18868 if (xmlSchemaCreateVCtxtOnPCtxt(pctxt) == -1)
18871 pctxt->vctxt->schema = pctxt->schema;
18873 res = xmlSchemaCheckFacet(facet, typeDecl, pctxt, name);
18877 pctxt->vctxt->schema = NULL;
18879 if (olderrs != pctxt->nberrors)
18880 return(pctxt->err);
19153 xmlSchemaAttributeGroupExpandRefs(xmlSchemaParserCtxtPtr pctxt,
19158 * @pctxt: the parser context
19171 xmlSchemaExpandAttributeGroupRefs(xmlSchemaParserCtxtPtr pctxt,
19223 if (xmlSchemaAttributeGroupExpandRefs(pctxt, gr) == -1)
19245 tmpWild = xmlSchemaAddWildcard(pctxt, pctxt->schema,
19250 if (xmlSchemaCloneWildcardNsConstraints(pctxt,
19258 if (xmlSchemaIntersectWildcards(pctxt, *completeWild,
19305 xmlSchemaCustomWarning(ACTXT_CAST pctxt,
19330 * @pctxt: the parser context
19341 xmlSchemaAttributeGroupExpandRefs(xmlSchemaParserCtxtPtr pctxt,
19349 if (xmlSchemaExpandAttributeGroupRefs(pctxt, WXS_BASIC_CAST attrGr,
19357 * @pctxt: the parser context
19367 xmlSchemaCheckAGPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
19403 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19433 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19501 xmlSchemaCheckAttrPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
19527 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19533 return(pctxt->err);
19543 ret = xmlSchemaVCheckCVCSimpleType(ACTXT_CAST pctxt,
19553 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19558 return(pctxt->err);
19599 xmlSchemaCheckElemPropsCorrect(xmlSchemaParserCtxtPtr pctxt,
19613 xmlSchemaCheckElementDeclComponent(head, pctxt);
19619 xmlSchemaPCustomErr(pctxt,
19641 xmlSchemaPCustomErrExt(pctxt,
19676 if (xmlSchemaCheckCOSDerivedOK(ACTXT_CAST pctxt, typeDef,
19681 xmlSchemaPCustomErrExt(pctxt,
19713 xmlSchemaPCustomErr(pctxt,
19730 xmlSchemaPErr(pctxt, elemDecl->node,
19745 vcret = xmlSchemaParseCheckCOSValidDefault(pctxt, node,
19882 * @pctxt: the schema parser context
19890 xmlSchemaCheckElementDeclConsistent(xmlSchemaParserCtxtPtr pctxt,
19917 ret = xmlSchemaCheckElementDeclConsistent(pctxt,
19941 xmlSchemaCustomErr(ACTXT_CAST pctxt,
19968 ret = xmlSchemaCheckElementDeclConsistent(pctxt, ctxtComponent,
19982 xmlSchemaInternalErr2(ACTXT_CAST pctxt,
20378 xmlSchemaParserCtxtPtr pctxt)
20384 xmlSchemaGetIDC(pctxt->schema, idc->ref->name,
20391 xmlSchemaPResCompAttrErr(pctxt,
20397 return(pctxt->err);
20402 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20408 return(pctxt->err);
20422 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20431 return(pctxt->err);
20440 xmlSchemaParserCtxtPtr pctxt)
20442 if (xmlSchemaGetAttributeDecl(pctxt->schema, prohib->name,
20445 xmlSchemaPResCompAttrErr(pctxt,
20465 xmlSchemaCheckSRCRedefineFirst(xmlSchemaParserCtxtPtr pctxt)
20468 xmlSchemaRedefPtr redef = WXS_CONSTRUCTOR(pctxt)->redefs;
20516 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20529 err = pctxt->err;
20620 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20629 err = pctxt->err;
20640 xmlSchemaCheckSRCRedefineSecond(xmlSchemaParserCtxtPtr pctxt)
20643 xmlSchemaRedefPtr redef = WXS_CONSTRUCTOR(pctxt)->redefs;
20696 err = xmlSchemaCheckDerivationOKRestriction2to4(pctxt,
20716 xmlSchemaAddComponents(xmlSchemaParserCtxtPtr pctxt,
20796 *table = xmlHashCreateDict(10, pctxt->dict);
20807 xmlSchemaCustomErr(ACTXT_CAST pctxt,
20825 if (xmlSchemaAddComponents(pctxt, rel->bucket) == -1)
20835 xmlSchemaFixupComponents(xmlSchemaParserCtxtPtr pctxt,
20838 xmlSchemaConstructionCtxtPtr con = pctxt->constructor;
20844 #define FIXHFAILURE if (pctxt->err == XML_SCHEMAP_INTERNAL) goto exit_failure;
20871 xmlSchemaCheckSRCRedefineFirst(pctxt);
20876 xmlSchemaAddComponents(pctxt, rootBucket);
20878 pctxt->ctxtType = NULL;
20912 (xmlSchemaElementPtr) item, pctxt);
20918 (xmlSchemaTypePtr) item, pctxt);
20923 (xmlSchemaAttributePtr) item, pctxt);
20928 (xmlSchemaAttributeUsePtr) item, pctxt);
20936 WXS_QNAME_CAST item, pctxt);
20943 xmlSchemaResolveModelGroupParticleReferences(pctxt,
20951 (xmlSchemaIDCPtr) item, pctxt);
20960 WXS_ATTR_PROHIB_CAST item, pctxt);
20967 if (pctxt->nberrors != 0)
20987 (xmlSchemaTypePtr) item, pctxt);
20989 if (pctxt->nberrors != 0)
20994 (xmlSchemaModelGroupDefPtr) item, pctxt);
20996 if (pctxt->nberrors != 0)
21001 (xmlSchemaAttributeGroupPtr) item, pctxt);
21003 if (pctxt->nberrors != 0)
21010 if (pctxt->nberrors != 0)
21025 xmlSchemaModelGroupToModelGroupDefFixup(pctxt,
21032 if (pctxt->nberrors != 0)
21044 xmlSchemaAttributeGroupExpandRefs(pctxt,
21053 if (pctxt->nberrors != 0)
21065 xmlSchemaFixupSimpleTypeStageOne(pctxt,
21074 if (pctxt->nberrors != 0)
21085 xmlSchemaCheckUnionTypeDefCircular(pctxt,
21094 if (pctxt->nberrors != 0)
21105 xmlSchemaFixupSimpleTypeStageTwo(pctxt, WXS_TYPE_CAST item);
21113 if (pctxt->nberrors != 0)
21125 xmlSchemaCheckAttrPropsCorrect(pctxt, WXS_ATTR_CAST item);
21132 if (pctxt->nberrors != 0)
21142 xmlSchemaCheckAttrUsePropsCorrect(pctxt,
21151 if (pctxt->nberrors != 0)
21164 xmlSchemaCheckAGPropsCorrect(pctxt, WXS_ATTR_GROUP_CAST item);
21172 if (pctxt->nberrors != 0)
21178 if (WXS_CONSTRUCTOR(pctxt)->redefs != NULL)
21179 xmlSchemaCheckSRCRedefineSecond(pctxt);
21180 if (pctxt->nberrors != 0)
21191 xmlSchemaFixupComplexType(pctxt, WXS_TYPE_CAST item);
21199 if (pctxt->nberrors != 0)
21221 (xmlSchemaElementPtr) elemDecl, pctxt);
21234 xmlSchemaCheckElementDeclConsistent(pctxt,
21245 if (pctxt->nberrors != 0)
21257 xmlSchemaBuildContentModel((xmlSchemaTypePtr) item, pctxt);
21264 if (pctxt->nberrors != 0)
21272 ret = pctxt->err;
21593 * @pctxt: a schema parser context
21613 xmlSchemaParserCtxtPtr pctxt;
21619 if (vctxt->pctxt == NULL) {
21624 pctxt = vctxt->pctxt;
21625 if (pctxt->constructor == NULL) {
21633 location = xmlSchemaBuildAbsoluteURI(pctxt->dict,
21640 ret = xmlSchemaAddSchemaDoc(pctxt, XML_SCHEMA_SCHEMA_IMPORT,
21660 (WXS_CONSTRUCTOR(pctxt)->bucket == NULL))
21661 WXS_CONSTRUCTOR(pctxt)->bucket = bucket;
21672 pctxt->nberrors = 0;
21673 pctxt->err = 0;
21674 pctxt->doc = bucket->doc;
21676 ret = xmlSchemaParseNewDocWithContext(pctxt, schema, bucket);
21678 pctxt->doc = NULL;
21682 if ((ret == 0) && (pctxt->nberrors != 0))
21683 ret = pctxt->err;
21684 if (pctxt->nberrors == 0) {
21691 xmlSchemaFixupComponents(pctxt, bucket);
21692 ret = pctxt->err;
21699 vctxt->nberrors += pctxt->nberrors;
21702 vctxt->nberrors += pctxt->nberrors;
21704 pctxt->doc = NULL;
21707 pctxt->doc = NULL;
24978 * if ((vctxt->pctxt == NULL) &&
27662 if (ctxt->pctxt != NULL)
27663 xmlSchemaFreeParserCtxt(ctxt->pctxt);
27773 if (ctxt->pctxt != NULL)
27774 xmlSchemaSetParserErrors(ctxt->pctxt, err, warn, ctx);
27795 if (ctxt->pctxt != NULL)
27796 xmlSchemaSetParserStructuredErrors(ctxt->pctxt, serror, ctx);
28065 xmlSchemaParserCtxtPtr pctxt;
28074 if ((vctxt->pctxt == NULL) &&
28077 pctxt = vctxt->pctxt;
28078 pctxt->xsiAssemble = 1;
28082 vctxt->schema = xmlSchemaNewSchema(pctxt);
28088 pctxt->constructor = xmlSchemaConstructionCtxtCreate(pctxt->dict);
28089 if (pctxt->constructor == NULL)
28091 pctxt->constructor->mainSchema = vctxt->schema;
28095 pctxt->ownsConstructor = 1;
28809 xmlParserCtxtPtr pctxt = NULL;
28819 pctxt = xmlNewParserCtxt();
28820 if (pctxt == NULL)
28822 old_sax = pctxt->sax;
28823 pctxt->sax = sax;
28824 pctxt->userData = user_data;
28827 xmlCtxtUseOptions(pctxt, options);
28829 pctxt->linenumbers = 1;
28830 xmlSchemaValidateSetLocator(ctxt, xmlSchemaValidateStreamLocator, pctxt);
28832 inputStream = xmlNewIOInputStream(pctxt, input, enc);;
28837 inputPush(pctxt, inputStream);
28838 ctxt->parserCtxt = pctxt;
28844 plug = xmlSchemaSAXPlug(ctxt, &(pctxt->sax), &(pctxt->userData));
28851 ctxt->sax = pctxt->sax;
28869 if (pctxt != NULL) {
28870 pctxt->sax = old_sax;
28871 xmlFreeParserCtxt(pctxt);