Package org.jpox.store.mapped.expression

Examples of org.jpox.store.mapped.expression.StringExpression


        {
            return new NumericExpression(qs, this, te);
        }
        else if (datastoreJavaType.equals(ClassNameConstants.JAVA_LANG_STRING))
        {
            return new StringExpression(qs, this, te);
        }
        else
        {
            // No querying of serialised Enums!
            return null;
View Full Code Here


     * @param te Expression for the datastore container
     * @return The JDOQL expression
     */
    public ScalarExpression newScalarExpression(QueryExpression qs, LogicSetExpression te)
    {
        return new StringExpression(qs, this, te);
    }
View Full Code Here

        return expr;
    }

    public ScalarExpression newScalarExpression(QueryExpression qs, LogicSetExpression te)
    {
        ScalarExpression expr = new StringExpression(qs, this, te);
        return expr;
    }
View Full Code Here

    {
        ArrayList args = new ArrayList();
        args.add(str);
        if (leading && trailing)
        {
            StringExpression strExpr = new StringExpression("RTRIM", args);
            args.clear();
            args.add(strExpr);
            return new StringExpression("LTRIM", args);
        }
        else if (leading)
        {
            return new StringExpression("LTRIM", args);
        }
        else if (trailing)
        {
            return new StringExpression("RTRIM", args);
        }
        return str;
    }
View Full Code Here

    {
        ArrayList args = new ArrayList();
        args.add(time);
        args.add(new StringLiteral(time.getQueryExpression(),null,"%I"));
        ArrayList args0 = new ArrayList();
        args0.add(new StringExpression("TO_CHAR",args));
        ArrayList types = new ArrayList();
        types.add("INTEGER");
        return new NumericExpression("CAST",args0,types);
    }   
View Full Code Here

    {
        ArrayList args = new ArrayList();
        args.add(time);
        args.add(new StringLiteral(time.getQueryExpression(),null,"%M"));
        ArrayList args0 = new ArrayList();
        args0.add(new StringExpression("TO_CHAR",args));
        ArrayList types = new ArrayList();
        types.add("INTEGER");
        return new NumericExpression("CAST",args0,types);
    }   
View Full Code Here

    {
        ArrayList args = new ArrayList();
        args.add(time);
        args.add(new StringLiteral(time.getQueryExpression(),null,"%S"));
        ArrayList args0 = new ArrayList();
        args0.add(new StringExpression("TO_CHAR",args));
        ArrayList types = new ArrayList();
        types.add("INTEGER");
        return new NumericExpression("CAST",args0,types);
    }   
View Full Code Here

        ArrayList args = new ArrayList();
        args.add(str);
        args.add(begin.add(getMapping(BigInteger.class, str).newLiteral(str.getQueryExpression(), BigInteger.ONE)));
        //Cloudscape 10.0
        //SUBSTR( string, start )
        return new StringExpression("SUBSTR", args);
    }
View Full Code Here

        args.add(str);
        args.add(begin.add(getMapping(BigInteger.class, str).newLiteral(str.getQueryExpression(), BigInteger.ONE)));
        args.add(end.sub(begin));
        //Cloudscape 10.0
        //SUBSTR( string, start, length )
        return new StringExpression("SUBSTR", args);
    }
View Full Code Here

        args.add(source);
        args.add(str);
        ScalarExpression literal = getMapping(BigInteger.class, source).newLiteral(source.getQueryExpression(), BigInteger.ZERO);
        args.add(literal);
        //JPOX_STRPOS( SearchString, stringSearched, [StartPosition] )
        return new BooleanExpression(new StringExpression("JPOX_STRPOS", args),ScalarExpression.OP_EQ,integerLiteral);
    }
View Full Code Here

TOP

Related Classes of org.jpox.store.mapped.expression.StringExpression

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.