• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/libxml2-26/libxml2/

Lines Matching refs:particle

656  * A particle component.
664 xmlSchemaTreeItemPtr next; /* next particle */
685 xmlSchemaTreeItemPtr children; /* first particle (OR "element decl" OR "wildcard") */
1145 return(BAD_CAST "particle");
4277 * @particle: the schema particle
4284 xmlSchemaContentModelDump(xmlSchemaParticlePtr particle, FILE * output, int depth)
4291 if (particle == NULL)
4297 if (particle->children == NULL) {
4298 fprintf(output, "MISSING particle term\n");
4301 term = particle->children;
4329 if (particle->minOccurs != 1)
4330 fprintf(output, " min: %d", particle->minOccurs);
4331 if (particle->maxOccurs >= UNBOUNDED)
4333 else if (particle->maxOccurs != 1)
4334 fprintf(output, " max: %d", particle->maxOccurs);
4344 if (particle->next != NULL)
4345 xmlSchemaContentModelDump((xmlSchemaParticlePtr) particle->next,
5499 * Adds an XML schema particle component.
5513 fprintf(stderr, "Adding particle component\n");
5518 xmlSchemaPErrMemory(ctxt, "allocating particle component",
6843 * TODO: Maybe we should better not create the particle,
6882 * Parsea a XML schema <any> element. A particle and wildcard
6887 * Returns the particle or NULL in case of error or if minOccurs==maxOccurs==0
6893 xmlSchemaParticlePtr particle;
6960 * Create the particle.
6962 particle = xmlSchemaAddParticle(ctxt, node, min, max);
6963 if (particle == NULL)
6965 particle->annot = annot;
6966 particle->children = (xmlSchemaTreeItemPtr) wild;
6968 return (particle);
8450 * Returns the element declaration or a particle; NULL in case
8451 * of an error or if the particle has minOccurs==maxOccurs==0.
8458 xmlSchemaParticlePtr particle = NULL;
8497 * Skip particle part if a global declaration.
8502 * The particle part ==================================================
8507 particle = xmlSchemaAddParticle(ctxt, node, min, max);
8508 if (particle == NULL)
8571 * Create the reference item and attach it to the particle.
8577 particle->children = (xmlSchemaTreeItemPtr) refer;
8578 particle->annot = annot;
8580 * Add the particle to pending components, since the reference
8583 WXS_ADD_PENDING(ctxt, particle);
8584 return ((xmlSchemaBasicItemPtr) particle);
8823 particle->children = (xmlSchemaTreeItemPtr) decl;
8824 return ((xmlSchemaBasicItemPtr) particle);
8830 if (particle != NULL)
8831 particle->annot = NULL;
9342 * We will return a particle component with a qname-component or
11191 * @particleNeeded: if a a model group with a particle
11216 xmlSchemaParticlePtr particle = NULL;
11242 * Create a particle
11244 particle = xmlSchemaAddParticle(ctxt, node, min, max);
11245 if (particle == NULL)
11247 particle->children = (xmlSchemaTreeItemPtr) item;
11460 return ((xmlSchemaTreeItemPtr) particle);
12554 xmlSchemaParticlePtr particle, int counter, xmlAutomataStatePtr end)
12562 elemDecl = (xmlSchemaElementPtr) particle->children;
12571 xmlSchemaPErr(pctxt, WXS_ITEM_NODE(particle),
12596 } else if (particle->maxOccurs == 1) {
12628 int maxOccurs = particle->maxOccurs == UNBOUNDED ?
12629 UNBOUNDED : particle->maxOccurs - 1;
12630 int minOccurs = particle->minOccurs < 1 ? 0 : particle->minOccurs - 1;
12656 if (particle->minOccurs == 0) {
12671 xmlSchemaParticlePtr particle)
12675 if (((xmlSchemaElementPtr) particle->children)->flags &
12680 ret = xmlSchemaBuildContentModelForSubstGroup(ctxt, particle, -1, NULL);
12685 elemDecl = (xmlSchemaElementPtr) particle->children;
12689 if (particle->maxOccurs == 1) {
12693 } else if ((particle->maxOccurs >= UNBOUNDED) &&
12694 (particle->minOccurs < 2)) {
12703 int maxOccurs = particle->maxOccurs == UNBOUNDED ?
12704 UNBOUNDED : particle->maxOccurs - 1;
12705 int minOccurs = particle->minOccurs < 1 ?
12706 0 : particle->minOccurs - 1;
12716 if (particle->minOccurs == 0) {
12727 * @particle: the particle component
12736 xmlSchemaParticlePtr particle)
12740 if (particle == NULL) {
12741 PERROR_INT("xmlSchemaBuildAContentModel", "particle is NULL");
12744 if (particle->children == NULL) {
12746 * Just return in this case. A missing "term" of the particle
12752 switch (particle->children->type) {
12758 wild = (xmlSchemaWildcardPtr) particle->children;
12763 if (particle->maxOccurs == 1) {
12801 particle->maxOccurs == UNBOUNDED ? UNBOUNDED :
12802 particle->maxOccurs - 1;
12804 particle->minOccurs < 1 ? 0 : particle->minOccurs - 1;
12835 if (particle->minOccurs == 0) {
12843 ret = xmlSchemaBuildContentModelForElement(pctxt, particle);
12853 if ((particle->minOccurs == 1) && (particle->maxOccurs == 1)) {
12854 sub = particle->children->children;
12865 if (particle->maxOccurs >= UNBOUNDED) {
12866 if (particle->minOccurs > 1) {
12875 particle->minOccurs - 1, UNBOUNDED);
12877 sub = particle->children->children;
12899 sub = particle->children->children;
12915 if (particle->minOccurs == 0) {
12921 } else if ((particle->maxOccurs > 1)
12922 || (particle->minOccurs > 1)) {
12931 particle->minOccurs - 1,
12932 particle->maxOccurs - 1);
12934 sub = particle->children->children;
12947 if ((particle->minOccurs == 0) || (ret == 1)) {
12953 sub = particle->children->children;
12969 if (particle->minOccurs == 0) {
12990 if (particle->maxOccurs == 1) {
12991 sub = particle->children->children;
13003 int maxOccurs = particle->maxOccurs == UNBOUNDED ?
13004 UNBOUNDED : particle->maxOccurs - 1;
13006 particle->minOccurs < 1 ? 0 : particle->minOccurs - 1;
13017 sub = particle->children->children;
13032 if (particle->minOccurs == 0) {
13046 sub = (xmlSchemaParticlePtr) particle->children->children;
13062 "<element> particle has no term");
13107 if (particle->minOccurs == 0) {
13127 WXS_ITEM_TYPE_NAME(particle->children), NULL);
13198 * or particle, which has an element declaration as it's
14640 * @particle: the particle
14648 xmlSchemaGetParticleTotalRangeMin(xmlSchemaParticlePtr particle)
14650 if ((particle->children == NULL) ||
14651 (particle->minOccurs == 0))
14653 if (particle->children->type == XML_SCHEMA_TYPE_CHOICE) {
14656 (xmlSchemaParticlePtr) particle->children->children;
14672 return (particle->minOccurs * min);
14677 (xmlSchemaParticlePtr) particle->children->children;
14689 return (particle->minOccurs * sum);
14696 * @particle: the particle
14704 xmlSchemaGetParticleTotalRangeMax(xmlSchemaParticlePtr particle)
14706 if ((particle->children == NULL) ||
14707 (particle->children->children == NULL))
14709 if (particle->children->type == XML_SCHEMA_TYPE_CHOICE) {
14712 (xmlSchemaParticlePtr) particle->children->children;
14728 return (particle->maxOccurs * max);
14733 (xmlSchemaParticlePtr) particle->children->children;
14745 if ((cur > 0) && (particle->maxOccurs == UNBOUNDED))
14750 return (particle->maxOccurs * sum);
14757 * @particle: the particle
14760 * Checks whether the given particle is emptiable.
14765 xmlSchemaIsParticleEmptiable(xmlSchemaParticlePtr particle)
14770 if ((particle == NULL) || (particle->minOccurs == 0) ||
14771 (particle->children == NULL))
14777 if (WXS_IS_MODEL_GROUP(particle->children)) {
14778 if (xmlSchemaGetParticleTotalRangeMin(particle) == 0)
15072 * The ball of letters below means, that if we have a particle
15102 /* Remove the particle. */
15105 /* Remove the particle. */
15110 * particle's {term}.
15117 * "1.2 the {term} property of a particle with
15126 "The particle's {max occurs} must be 1, since the "
15824 * type}'s particle must be ���emptiable��� as defined by
15835 "and a particle emptiable", NULL);
16279 * definition itself must specify a particle.
16284 "The content type must specify a particle", NULL);
16315 * URGENT TODO SPEC (1.4.3.2.2.2) "The particle of the
16317 * of the {base type definition}'s particle, as defined
16485 * and have a particle which is ���emptiable��� as defined in
16494 "a simple type or 'mixed' and an emptiable particle", NULL);
16514 * definition} must be elementOnly or mixed and have a particle
16524 "particle", NULL);
16547 * SPEC (5.4.2) "The particle of the complex type definition itself
16548 * must be a ���valid restriction��� of the particle of the {content
16684 * is mixed and a particle emptiable.
16725 "mixed content and particle emptiable. The base type "
16788 * @r: the restricting element declaration particle
16789 * @b: the base element declaration particle
16895 * @r: the restricting element declaration particle
16896 * @b: the base wildcard particle
16915 * SPEC "For an element declaration particle to be a ���valid restriction���
16916 * of a wildcard particle all of the following must be true:"
16939 * @r: the restricting element declaration particle
16940 * @b: the base model group particle
16965 * @r: the restricting wildcard particle
16966 * @b: the base wildcard particle
17021 * Particle Valid (Restriction) (cos-particle-restrict)
17042 * SPEC (1) "They are the same particle."
17055 * @r: the model group particle
17056 * @b: the base wildcard particle
17079 * SPEC "For a group particle to be a ���valid restriction��� of a
17080 * wildcard particle..."
17109 * @r: the <all> or <sequence> model group particle
17110 * @b: the base <all> or <sequence> model group particle
17135 * SPEC "For an all or sequence group particle to be a ���valid
17136 * restriction��� of another group particle with the same {compositor}..."
18027 "mixed as emptiable particle\n");
18268 * an emptiable particle, then a simple type definition which
18326 xmlSchemaParticlePtr particle =
18338 if ((particle == NULL) ||
18339 ((particle->type == XML_SCHEMA_TYPE_PARTICLE) &&
18340 ((particle->children->type == XML_SCHEMA_TYPE_ALL) ||
18341 (particle->children->type == XML_SCHEMA_TYPE_SEQUENCE) ||
18342 ((particle->children->type == XML_SCHEMA_TYPE_CHOICE) &&
18343 (particle->minOccurs == 0))) &&
18344 ( ((xmlSchemaTreeItemPtr) particle->children)->children == NULL))) {
18348 * a particle whose properties are as follows:..."
18351 * minOccurs/maxOccurs = 1 (i.e. a "particle emptiable").
18355 if ((particle == NULL) ||
18356 (particle->children->type != XML_SCHEMA_TYPE_SEQUENCE)) {
18358 * Create the particle.
18360 particle = xmlSchemaAddParticle(pctxt,
18362 if (particle == NULL)
18367 particle->children = (xmlSchemaTreeItemPtr)
18370 if (particle->children == NULL)
18373 type->subtypes = (xmlSchemaTypePtr) particle;
18385 * SPEC (2.2) "otherwise the particle corresponding to the
18483 * Create the particle.
18485 particle = xmlSchemaAddParticle(pctxt,
18487 if (particle == NULL)
18492 particle->children = (xmlSchemaTreeItemPtr)
18495 if (particle->children == NULL)
18497 WXS_TYPE_CONTENTTYPE(type) = (xmlSchemaTypePtr) particle;
18499 * SPEC "the particle of the {content type} of
18501 * Create a duplicate of the base type's particle
18504 particle->children->children =
18509 if (particle->children->children == NULL)
18511 particle = (xmlSchemaParticlePtr)
18512 particle->children->children;
18513 particle->children =
18518 particle->next = effectiveContent;
18521 * new-particle
18523 * new-particle
18525 * this-particle
18539 particle->children->children =
18875 * @particle: the first particle
18880 * Returns the particle with the circular model group definition reference,
18885 xmlSchemaTreeItemPtr particle)
18891 for (; particle != NULL; particle = particle->next) {
18892 term = particle->children;
18899 return (particle);
18944 * of a group there must not be at any depth a particle whose {term}
18986 * of the referencing particle.
18999 xmlSchemaParticlePtr particle = WXS_MODELGROUP_PARTICLE(mg);
19001 while (particle != NULL) {
19002 if ((WXS_PARTICLE_TERM(particle) == NULL) ||
19003 ((WXS_PARTICLE_TERM(particle))->type !=
19006 particle = WXS_PTC_CAST particle->next;
19009 if (WXS_MODELGROUPDEF_MODEL(WXS_PARTICLE_TERM(particle)) == NULL) {
19011 * TODO: Remove the particle.
19013 WXS_PARTICLE_TERM(particle) = NULL;
19014 particle = WXS_PTC_CAST particle->next;
19018 * Assign the model group to the {term} of the particle.
19020 WXS_PARTICLE_TERM(particle) =
19021 WXS_TREE_CAST WXS_MODELGROUPDEF_MODEL(WXS_PARTICLE_TERM(particle));
19023 particle = WXS_PTC_CAST particle->next;
19869 * @ctxtParticle: the first particle of the context component
19870 * @searchParticle: the element declaration particle to be analysed
19891 * Just return in this case. A missing "term" of the particle
19951 sub = WXS_PARTICLE_TERM(particle)->children; (xmlSchemaParticlePtr)
19983 * @item: an schema element declaration/particle
20009 * @particle: a particle component
20020 xmlSchemaParticlePtr particle = WXS_MODELGROUP_PARTICLE(mg);
20027 while (particle != NULL) {
20028 if ((WXS_PARTICLE_TERM(particle) == NULL) ||
20029 ((WXS_PARTICLE_TERM(particle))->type !=
20034 ref = WXS_QNAME_CAST WXS_PARTICLE_TERM(particle);
20039 particle->children = NULL;
20045 NULL, WXS_ITEM_NODE(particle), "ref", ref->name,
20047 /* TODO: remove the particle. */
20052 /* TODO: remove the particle. */
20056 * itself to the "term" of the particle. This will ease
20070 * (1.2) "the {term} property of a particle [... of] the "
20076 WXS_ITEM_NODE(particle), NULL,
20081 /* TODO: remove the particle. */
20084 particle->children = (xmlSchemaTreeItemPtr) refItem;
20090 particle->children = (xmlSchemaTreeItemPtr) refItem;
20093 particle = WXS_PTC_CAST particle->next;
20837 * (local components), and those particle components need a bucket
20887 * - the term of the particle (e.g. a model group)
20999 * Such a reference is reflected by a particle at the component
25901 * type}'s particle must be ���emptiable��� as defined by
25912 "or mixed content and a particle emptiable");
26622 * particle, as defined in Element Sequence Locally Valid