Package com.sun.msv.verifier.regexp

Examples of com.sun.msv.verifier.regexp.REDocumentDeclaration


    public REDocumentDeclaration parseVGM( InputSource source )
        throws SAXException, ParserConfigurationException, java.io.IOException {
       
        Grammar g = _loadSchema(source);
        if(g==null)        return null;
        else            return new REDocumentDeclaration(g);
    }
View Full Code Here


                    return;
                }
               
                XMLReader r = factory.newSAXParser().getXMLReader();
                Verifier v = new Verifier(
                    new REDocumentDeclaration(grammar),
//                    new REDocumentDeclaration(grammar.getTopLevel(),localPool),
                    new ErrorHandlerImpl() );
                r.setContentHandler(v);
                try
                {
View Full Code Here

     *
     * <p>
     * override this method to use a different verifier implementation.
     */
    protected IVerifier getVerifier( Grammar grammar ) {
        return new Verifier( new REDocumentDeclaration(grammar),
            new ReportErrorHandler() );
    }
View Full Code Here

            return new IDConstraintChecker(
                (XMLSchemaGrammar)g,
                new ErrorHandlerImpl() );
        else
            return new com.sun.msv.verifier.Verifier(
                new REDocumentDeclaration(g),
                new ErrorHandlerImpl() );
    }
View Full Code Here

        DeclImpl[] ri = new DeclImpl[rules.length];
        System.arraycopy( rules,0, ri,0, rules.length );
       
        return new TREXIslandVerifier(
            new RulesAcceptor(
                new REDocumentDeclaration( getGrammar() ), ri ) );
    }
View Full Code Here

        if( grammar instanceof XMLSchemaGrammar )
            // use verifier+identity constraint checker.
            verifier = new XMLSchemaVerifier( (XMLSchemaGrammar)grammar );
        else
            // validate normally by using Verifier.
            verifier = new SimpleVerifier( new REDocumentDeclaration(grammar) );
       
       
        boolean allValid = true;
       
        for( int i=0; i<fileNames.size(); i++ )    {
View Full Code Here

        if(!validate)    break;
       
        // check the validity of generated document.
        DOM2toSAX2 d2s = new DOM2toSAX2();
        Verifier v = new Verifier(
          new REDocumentDeclaration(grammar),
          debug?
            (ErrorHandler)new ErrorHandlerImpl():
            (ErrorHandler)new IgnoreErrorHandler() );
        d2s.setContentHandler(v);
        d2s.traverse(dom);
View Full Code Here

        DeclImpl[] ri = new DeclImpl[rules.length];
        System.arraycopy( rules,0, ri,0, rules.length );
       
        return new TREXIslandVerifier(
            new RulesAcceptor(
                new REDocumentDeclaration( getGrammar() ), ri ) );
    }
View Full Code Here

                            Locator locator ) {
       
        // create a VerifierFilter and configure it
        // so that error messages will be sent to the core,
        Verifier v = new Verifier(
            new REDocumentDeclaration(grammar),
            new ErrorHandlerAdaptor(_core,locator) );
        v.setPanicMode( true );

        return new ValidatingUnmarshaller(
            new VerifierFilter( v ), _core );
View Full Code Here

                            Locator locator ) {
       
        // create a VerifierFilter and configure it
        // so that error messages will be sent to the core,
        Verifier v = new Verifier(
            new REDocumentDeclaration(grammar),
            new ErrorHandlerAdaptor(_core,locator) );
        v.setPanicMode( true );

        return new ValidatingUnmarshaller(
            new VerifierFilter( v ), _core );
View Full Code Here

TOP

Related Classes of com.sun.msv.verifier.regexp.REDocumentDeclaration

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.