use of org.datanucleus.query.expression.DyadicExpression in project datanucleus-api-jdo by datanucleus.
the class ComparableExpressionImpl method lt.
/* (non-Javadoc)
* @see org.datanucleus.query.typesafe.Expression#lt(org.datanucleus.query.typesafe.ComparableExpression)
*/
public BooleanExpression lt(ComparableExpression expr) {
Expression leftQueryExpr = queryExpr;
Expression rightQueryExpr = ((ExpressionImpl) expr).getQueryExpression();
org.datanucleus.query.expression.Expression queryExpr = new DyadicExpression(leftQueryExpr, org.datanucleus.query.expression.Expression.OP_LT, rightQueryExpr);
return new BooleanExpressionImpl(queryExpr);
}
use of org.datanucleus.query.expression.DyadicExpression in project datanucleus-api-jdo by datanucleus.
the class ComparableExpressionImpl method lteq.
/* (non-Javadoc)
* @see org.datanucleus.query.typesafe.Expression#lteq(java.lang.Object)
*/
public BooleanExpression lteq(T t) {
Expression leftQueryExpr = queryExpr;
Expression rightQueryExpr = new Literal(t);
org.datanucleus.query.expression.Expression queryExpr = new DyadicExpression(leftQueryExpr, org.datanucleus.query.expression.Expression.OP_LTEQ, rightQueryExpr);
return new BooleanExpressionImpl(queryExpr);
}
use of org.datanucleus.query.expression.DyadicExpression in project datanucleus-api-jdo by datanucleus.
the class ComparableExpressionImpl method gteq.
/* (non-Javadoc)
* @see org.datanucleus.query.typesafe.Expression#gteq(org.datanucleus.query.typesafe.ComparableExpression)
*/
public BooleanExpression gteq(ComparableExpression expr) {
Expression leftQueryExpr = queryExpr;
Expression rightQueryExpr = ((ExpressionImpl) expr).getQueryExpression();
org.datanucleus.query.expression.Expression queryExpr = new DyadicExpression(leftQueryExpr, org.datanucleus.query.expression.Expression.OP_GTEQ, rightQueryExpr);
return new BooleanExpressionImpl(queryExpr);
}
use of org.datanucleus.query.expression.DyadicExpression in project datanucleus-api-jdo by datanucleus.
the class ExpressionImpl method ne.
/* (non-Javadoc)
* @see org.datanucleus.query.typesafe.Expression#ne(java.lang.Object)
*/
public BooleanExpression ne(T t) {
org.datanucleus.query.expression.Expression leftQueryExpr = queryExpr;
org.datanucleus.query.expression.Expression rightQueryExpr = new Literal(t);
return new BooleanExpressionImpl(new DyadicExpression(leftQueryExpr, org.datanucleus.query.expression.Expression.OP_NOTEQ, rightQueryExpr));
}
use of org.datanucleus.query.expression.DyadicExpression in project datanucleus-api-jdo by datanucleus.
the class ExpressionImpl method ne.
/* (non-Javadoc)
* @see org.datanucleus.query.typesafe.Expression#ne(org.datanucleus.query.typesafe.Expression)
*/
public BooleanExpression ne(Expression expr) {
if (expr == null) {
// Assume they meant to compare with NULL Literal
return this.ne((T) null);
}
org.datanucleus.query.expression.Expression leftQueryExpr = queryExpr;
org.datanucleus.query.expression.Expression rightQueryExpr = ((ExpressionImpl) expr).getQueryExpression();
return new BooleanExpressionImpl(new DyadicExpression(leftQueryExpr, org.datanucleus.query.expression.Expression.OP_NOTEQ, rightQueryExpr));
}
Aggregations