/** * Apply an "is null" constraint */ public AuditCriterion isNull() { return new NullAuditExpression( alias, propertyNameGetter ); }
/** * Apply an "equal" constraint to another property * * @param otherAlias the alias of the entity which owns the other property. */ public AuditCriterion eqProperty(String otherAlias, String otherPropertyName) { return new PropertyAuditExpression( alias, propertyNameGetter, otherAlias, otherPropertyName, "=" ); }
/** * Apply an "equal" constraint */ public AuditCriterion eq(T value) { return new SimpleAuditExpression( alias, propertyNameGetter, value, "=" ); }
/** * Applies an "equals" criteria predicate. * * @param id the value to test equality with * @return the criterion. */ public AuditCriterion eq(Object id) { return new RelatedAuditEqualityExpression( alias, propertyNameGetter, id, true ); }
/** * Return the conjuction of two criterions. */ public static AuditCriterion and(AuditCriterion lhs, AuditCriterion rhs) { return new LogicalAuditExpression( lhs, rhs, "and" ); }
/** * Applies an "in" criteria predicate. * * @param values the values to test with * @return the criterion */ public AuditCriterion in(Object[] values) { return new RelatedAuditInExpression( alias, propertyNameGetter, values ); } }
/** * Apply an "in" constraint */ public AuditCriterion in(T[] values) { return new InAuditExpression( alias, propertyNameGetter, values ); }
/** * Apply a "not equal" constraint */ @Override public AuditCriterion ne(Object id) { return new IdentifierEqAuditExpression( alias, id, false ); }
/** * Return the negation of a criterion. */ public static AuditCriterion not(AuditCriterion expression) { return new NotAuditExpression( expression ); }
/** * Apply a "between" constraint */ public AuditCriterion between(T lo, T hi) { return new BetweenAuditExpression( alias, propertyNameGetter, lo, hi ); }
/** * Apply an "is not null" constraint to the another property */ public AuditCriterion isNotNull() { return new NotNullAuditExpression( alias, propertyNameGetter ); }
/** * Apply a "greater than or equal" constraint to another property * * @param otherAlias the alias of the entity which owns the other property. */ public AuditCriterion geProperty(String otherAlias, String otherPropertyName) { return new PropertyAuditExpression( alias, propertyNameGetter, otherAlias, otherPropertyName, ">=" ); }
/** * Apply a "not equal" constraint */ public AuditCriterion ne(T value) { return new SimpleAuditExpression( alias, propertyNameGetter, value, "<>" ); }
/** * Applies a "not equals" criteria predicate. * * @param id the value to test inequality with * @return the criterion */ public AuditCriterion ne(Object id) { return new RelatedAuditEqualityExpression( alias, propertyNameGetter, id, false ); }
/** * Return the disjuction of two criterions. */ public static AuditCriterion or(AuditCriterion lhs, AuditCriterion rhs) { return new LogicalAuditExpression( lhs, rhs, "or" ); }
/** * Apply a "less than" constraint to another property * * @param otherAlias the alias of the entity which owns the other property. */ public AuditCriterion ltProperty(String otherAlias, String otherPropertyName) { return new PropertyAuditExpression( alias, propertyNameGetter, otherAlias, otherPropertyName, "<" ); }
/** * Apply a "greater than" constraint */ public AuditCriterion gt(T value) { return new SimpleAuditExpression( alias, propertyNameGetter, value, ">" ); }
/** * Apply a "not equal" constraint to another property * * @param otherAlias the alias of the entity which owns the other property. */ public AuditCriterion neProperty(String otherAlias, String otherPropertyName) { return new PropertyAuditExpression( alias, propertyNameGetter, otherAlias, otherPropertyName, "<>" ); }
/** * Apply a "like" constraint */ public AuditCriterion like(T value) { return new SimpleAuditExpression( alias, propertyNameGetter, value, " like " ); }
/** * Apply a "greater than" constraint to another property * * @param otherAlias the alias of the entity which owns the other property. */ public AuditCriterion gtProperty(String otherAlias, String otherPropertyName) { return new PropertyAuditExpression( alias, propertyNameGetter, otherAlias, otherPropertyName, ">" ); }