Package org.exolab.jms.selector

Examples of org.exolab.jms.selector.Type


     * expected
     */
    public static void check(final SelectorAST node, final Type expected)
        throws TypeMismatchException {

        Type type = node.getReturnType();
        if (type != expected && type != Type.UNDEFINED) {
            String msg = "expecting a " + expected + " expression, found a "
                + type;
            throw new TypeMismatchException(node.getContext(), msg);
        }
View Full Code Here


     */
    public static void check(final String operator, final SelectorAST node,
                             final Type expected)
        throws TypeMismatchException {

        Type type = node.getReturnType();
        if (type != expected && type != Type.UNDEFINED) {
            String msg = "expecting a " + expected
                + " expression for operator " + operator + ", found a " + type;
            throw new TypeMismatchException(node.getContext(), msg);
        }
View Full Code Here

    public static void checkComparison(final String operator,
                                       final SelectorAST left,
                                       final SelectorAST right)
        throws TypeMismatchException {

        Type lhs = left.getReturnType();
        Type rhs = right.getReturnType();

        if (lhs == Type.UNDEFINED || rhs == Type.UNDEFINED) {
            // can't evaluate this at parse time.
        } else if (lhs == Type.STRING && rhs == Type.STRING) {
            checkStringComparison(operator, left, right);
View Full Code Here

TOP

Related Classes of org.exolab.jms.selector.Type

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.