Package xbird.xquery.parser

Examples of xbird.xquery.parser.SyntaxError


    public XQueryModule parse(Reader r, URI baseUri) throws XQueryException {
        final XQueryParser parser;
        try {
            parser = new XQueryParser(r);
        } catch (TokenMgrError e) {
            throw new SyntaxError("err:XPST0003", e);
        }
        if(_statEnv != null) {
            parser.setStaticContext(_statEnv);
        } else {
            this._statEnv = parser.getStaticContext();
View Full Code Here


        return _bodyExpression.eval(argv, dynEnv);
    }

    public static void checkAsPredefinedFunction(String nsuri) throws XQueryException {
        if(nsuri == null || nsuri.length() == 0) {
            throw new SyntaxError("err:XQST0060");
        }
        if(XQueryConstants.XML_URI.equals(nsuri) || XQueryConstants.XS_URI.equals(nsuri)
                || XQueryConstants.XSI_URI.equals(nsuri) || XQueryConstants.FN_URI.equals(nsuri)
                || XQueryConstants.XDT_URI.equals(nsuri)) {
            throw new SyntaxError("err:XQST0045");
        }
    }
View Full Code Here

    }

    public static UserFunction createUserFunction(Module declaredModule, QualifiedName funcName, List<ParametricVariable> parameters, Type returnType)
            throws XQueryException {
        if(declaredModule.lookupFunction(funcName, parameters) != null) {
            throw new SyntaxError("err:XPST0017");
        }
        final UserFunction func = new UserFunction(declaredModule, funcName, parameters, returnType);
        declaredModule.declareLocalFunction(func);
        return func;
    }
View Full Code Here

            }
            final URI uri;
            try {
                uri = new URI(baseURIString);
            } catch (URISyntaxException e) {
                throw new SyntaxError("err:XQST0046", e);
            }
            this.baseURI = uri;
            return uri;
        }
    }
View Full Code Here

            }
            final URI uri;
            try {
                uri = new URI(baseURIString);
            } catch (URISyntaxException e) {
                throw new SyntaxError("err:XQST0046", e);
            }
            this.baseURI = uri;
            return uri;
        }
    }
View Full Code Here

TOP

Related Classes of xbird.xquery.parser.SyntaxError

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.