/** * @return A less than or equal to Expression. */ public Expression lte(E value) { return ExpressionFactory.lessOrEqualExp(getExpression(), value); }
/** * A convenience method to create an OBJ_PATH "less than or equal to" * expression. */ public static Expression lessOrEqualExp(String pathSpec, Object value) { return lessOrEqualExp(new ASTObjPath(pathSpec), value); }
/** * @return Represents a less than or equal relationship between two * attributes (columns). */ public Expression lte(Property<?> value) { return ExpressionFactory.lessOrEqualExp(getExpression(), value.getExpression()); }
Expression lte(Filter filter) { return (filter.getValue() == null) ? expFalse() : lessOrEqualExp(filter.getProperty(), filter.getValue()); }
newExpression = ExpressionFactory.lessExp(key, numVal); } else if (t == Filter.LESS_THAN_EQUAL) { newExpression = ExpressionFactory.lessOrEqualExp(key, numVal); } else if (t == Filter.GREATER_THAN) { newExpression = ExpressionFactory.greaterExp(key, numVal); continue; } else if (t == Filter.LESS_THAN || t == Filter.LESS_THAN_EQUAL) { newExpression = ExpressionFactory.lessOrEqualExp(key, numVal); } else if (t == Filter.GREATER_THAN || t == Filter.GREATER_THAN_EQUAL) { newExpression = ExpressionFactory.greaterOrEqualExp(key, numVal); newExpression = ExpressionFactory.lessExp(key, dateVal); } else if (t == Filter.LESS_THAN_EQUAL) { newExpression = ExpressionFactory.lessOrEqualExp(key, dateVal); } else if (t == Filter.GREATER_THAN) { newExpression = ExpressionFactory.greaterExp(key, dateVal);
public void addRange(String fieldName, Object start, Object end) { ObjEntityViewField field = queryTarget.getField(fieldName); String path = null; if (field.getCalcType().getValue() == CalcTypeEnum.NO_CALC_TYPE_VALUE) { path = field.getObjAttribute().getName(); } else if (field.isLookup()) { path = field.getObjRelationship().getName(); } Object rawStart = field.toRawValue(start); Object rawEnd = field.toRawValue(end); Expression expr = null; if (rawStart != null && rawEnd != null) expr = ExpressionFactory.betweenExp(path, rawStart, rawEnd); else if (rawStart != null) expr = ExpressionFactory.greaterOrEqualExp(path, rawStart); else if (rawEnd != null) expr = ExpressionFactory.lessOrEqualExp(path, rawEnd); if (expr != null) conditions.add(expr); }