Package com.sun.msv.grammar

Examples of com.sun.msv.grammar.Expression


       
        reader.addBackPatchJob( new GrammarReader.BackPatch(){
            public State getOwnerState() { return ElementDeclState.this; }
            public void patch() {
               
                Expression e=null;
               
                if( reader.isSchemaNamespace(s[0]) )
                    // datatypes of XML Schema part 2
                    e = reader.resolveBuiltinSimpleType(s[1]);
               
View Full Code Here


            // check conflicting elements
            if(elemDupChecker!=null)
                elemDupChecker.add(exp);
           
            // push context element,
            final Expression oldContext = errorContext;
            final DuplicateAttributesChecker oldADC = attDupChecker;
            final DuplicateElementsChecker oldEDC = elemDupChecker;
           
            errorContext = exp;
            attDupChecker = new DuplicateAttributesChecker();
View Full Code Here

            attDupChecker.add(exp);
           
            // check infinite name
            checkAttributeInfiniteName(exp);
           
            final Expression oldContext = errorContext;
           
            errorContext = exp;
           
            exp.exp.getExpandedExp(reader.pool).visit(inAttribute);
            errorContext = oldContext;
View Full Code Here

    exp.contentModel = exp.contentModel.visit(this);
    return exp;
  }
 
  public Expression onAttribute( AttributeExp exp ) {
    Expression content = exp.exp.visit(this);
    if( content==Expression.nullSet )
      return Expression.epsilon;
    else
      return pool.createAttribute( exp.nameClass, content );
  }
View Full Code Here

        return module;
    }
   
    public void bind( SchemaProvider provider, ErrorHandler handler ) throws SAXException {
        {// wrap up anyOtherElements.
            Expression pseudoContentModel = createChoiceOfAllExportedRules(provider);
               
            Iterator itr = pendingAnyOtherElements.iterator();
            while( itr.hasNext() )
                ((AnyOtherElementExp)itr.next()).wrapUp(module,pseudoContentModel,provider,handler);
            pendingAnyOtherElements = null;
View Full Code Here

     * creates a choice expression of all exported rules in the given provider.
     *
     * this expression is used as a pseudo content model of anyOtherElement.
     */
    private Expression createChoiceOfAllExportedRules( SchemaProvider provider ) {
        Expression exp = Expression.nullSet;
       
        Iterator itr = provider.iterateNamespace();
        while( itr.hasNext() ) {
            String namespace = (String)itr.next();
            IslandSchema is = provider.getSchemaByNamespace(namespace);
View Full Code Here

    private boolean foundConcur;

    public void onConcur(ConcurExp exp) {
        foundConcur = true;
        exp.exp1.visit(this);
        Expression content1 = content;
        Expression continuation1 = continuation;

        exp.exp2.visit(this);

        content = pool.createConcur(content, content1);
        continuation = pool.createConcur(continuation, continuation1);
View Full Code Here

            exp.exp2.visit(this);
            continuation = pool.createInterleave(continuation, exp.exp1);
            return;
        }

        Expression content1 = content;
        Expression continuation1 = continuation;

        exp.exp2.visit(this);

        if (content == Expression.nullSet) {
            content = content1;
View Full Code Here

    public void onOther(OtherExp exp) {
        exp.exp.visit(this);
    }
    public void onChoice(ChoiceExp exp) {
        exp.exp1.visit(this);
        Expression content1 = content;
        Expression continuation1 = continuation;

        exp.exp2.visit(this);

        content = pool.createChoice(content, content1);
        continuation = pool.createChoice(continuation, continuation1);
View Full Code Here

        continuation = pool.createSequence(continuation, exp.exp2);

        if (!exp.exp1.isEpsilonReducible())
            return;

        Expression content1 = content;
        Expression continuation1 = continuation;

        exp.exp2.visit(this);

        if (content == Expression.nullSet) {
            content = content1;
View Full Code Here

TOP

Related Classes of com.sun.msv.grammar.Expression

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.