Class ElementWildcard

    • Method Detail

      • setWildcard

        public void setWildcard​(Wildcard wildcard)
      • getWildcard

        public Wildcard getWildcard()
      • isEmptiable

        public boolean isEmptiable()
        Determine if this particle can be empty
        Specified by:
        isEmptiable in class Particle
        Returns:
        true if the particle matches empty content
      • isPointless

        public boolean isPointless​(ModelGroup container)
        Test whether the particle is pointless, as described in XML Schema Part 1 Schema Component Constraint: Particle Valid (Restriction)
        Specified by:
        isPointless in class Particle
        Parameters:
        container - the model group containing this particle; null if there is no containing model group
        Returns:
        true if the particle is pointless (for example, a sequence of one item)
      • getTerm

        public Term getTerm()
        Get the term represented by this particle
        Specified by:
        getTerm in class Particle
        Returns:
        the corresponding term
      • fixup

        public boolean fixup​(SchemaCompiler compiler)
        Check references from this component to other components
        Specified by:
        fixup in interface UserSchemaComponent
        Specified by:
        fixup in class Particle
        Parameters:
        compiler - the schema compiler
        Returns:
        true if all is well, false if errors found
      • compile

        public void compile​(SchemaCompiler compiler)
        Description copied from class: Particle
        Compile a particle
        Specified by:
        compile in class Particle
        Parameters:
        compiler - the schema compiler
      • getElementParticleType

        public SchemaType getElementParticleType​(int elementName)
        Find an element particle within this complex type definition having a given element name (identified by elementName), and return the schema type associated with that element particle. If there is no such particle, return null. If the elementName matches an element wildcard, return the type of the global element declaration with the given name if one exists, or AnyType if none exists and lax validation is permitted by the wildcard.
        Specified by:
        getElementParticleType in class Particle
        Parameters:
        elementName - Identifies the name of the child element within this content model
        Returns:
        the type of the element identified by the given name fingerprint. The consistency rule "Element Declarations Consistent" ensures that if there are multiple matching declarations, they have consistent types
      • containsElementWildcard

        public boolean containsElementWildcard()
        Ask whether the particle contains an element wildcard
        Specified by:
        containsElementWildcard in class Particle
        Returns:
        true if the particle is an element wildcard, or contains one
      • gatherAllPermittedElements

        public void gatherAllPermittedElements​(IntHashSet result,
                                               boolean ignoreWildcards)
                                        throws SchemaException
        Find the set of all element particles allowed within the content model of this particle, identified by their integer fingerprints.
        Specified by:
        gatherAllPermittedElements in class Particle
        Parameters:
        result - an initially-empty integer set in which the results are accumulated
        ignoreWildcards - true if wildcards are to be ignored. If false, the value XS_INVALID_NAME is added
        Throws:
        SchemaException - if an error is found in the schema
      • validate

        public boolean validate​(SchemaCompiler compiler)
                         throws SchemaException
        Check the validity (consistency) of this element wildcard definition.
        Specified by:
        validate in interface UserSchemaComponent
        Specified by:
        validate in class Particle
        Parameters:
        compiler - the schema compiler
        Returns:
        true if validation succeeded, false if errors were found.
        Throws:
        SchemaException - if an error is found and the error listener decides that the error is fatal
      • getTermComponentAsFunction

        public FunctionItem getTermComponentAsFunction()