Example usage for Java org.hibernate.criterion Restrictions fields, constructors, methods, implement or subclass
The text is from its open source code.
Criterion | allEq(Map Apply an "equals" constraint to each property in the key set of a Map |
LogicalExpression | and(Criterion lhs, Criterion rhs) Return the conjuction of two expressions |
Conjunction | and(Criterion... predicates) Return the conjuction of multiple expressions |
Criterion | between(String propertyName, Object low, Object high) Apply a "between" constraint to the named property |
Conjunction | conjunction() Group expressions together in a single conjunction (A and B and C...). |
Conjunction | conjunction(Criterion... conditions) Group expressions together in a single conjunction (A and B and C...). |
Disjunction | disjunction() Group expressions together in a single disjunction (A or B or C...). |
SimpleExpression | eq(String propertyName, Object value) Apply an "equal" constraint to the named property |
Criterion | eqOrIsNull(String propertyName, Object value) Apply an "equal" constraint to the named property. |
PropertyExpression | eqProperty(String propertyName, String otherPropertyName) Apply an "equal" constraint to two properties |
SimpleExpression | ge(String propertyName, Object value) Apply a "greater than or equal" constraint to the named property |
PropertyExpression | geProperty(String propertyName, String otherPropertyName) Apply a "greater than or equal" constraint to two properties |
SimpleExpression | gt(String propertyName, Object value) Apply a "greater than" constraint to the named property |
PropertyExpression | gtProperty(String propertyName, String otherPropertyName) Apply a "greater than" constraint to two properties |
Criterion | idEq(Object value) Apply an "equal" constraint to the identifier property |
Criterion | ilike(String propertyName, Object value) A case-insensitive "like" (similar to Postgres ilike operator) |
Criterion | ilike(String propertyName, String value, MatchMode matchMode) A case-insensitive "like" (similar to Postgres ilike operator) using the provided match mode |
Criterion | in(String propertyName, Object... values) Apply an "in" constraint to the named property. |
Criterion | in(String propertyName, Collection values) Apply an "in" constraint to the named property. |
Criterion | isEmpty(String propertyName) Constrain a collection valued property to be empty |
Criterion | isNotEmpty(String propertyName) Constrain a collection valued property to be non-empty |
Criterion | isNotNull(String propertyName) Apply an "is not null" constraint to the named property |
Criterion | isNull(String propertyName) Apply an "is null" constraint to the named property |
SimpleExpression | leExpression le(String propertyName, Object value) Apply a "less than or equal" constraint to the named property |
PropertyExpression | leProperty(String propertyName, String otherPropertyName) Apply a "less than or equal" constraint to two properties |
SimpleExpression | like(String propertyName, Object value) Apply a "like" constraint to the named property |
SimpleExpression | like(String propertyName, String value, MatchMode matchMode) Apply a "like" constraint to the named property using the provided match mode |
SimpleExpression | lt(String propertyName, Object value) Apply a "less than" constraint to the named property |
PropertyExpression | ltProperty(String propertyName, String otherPropertyName) Apply a "less than" constraint to two properties |
NaturalIdentifier | naturalId() Consider using any of the natural id based loading stuff from session instead, especially in cases where the restriction is the full set of natural id values. |
SimpleExpression | ne(String propertyName, Object value) Apply a "not equal" constraint to the named property |
Criterion | neOrIsNotNull(String propertyName, Object value) Apply a "not equal" constraint to the named property. |
PropertyExpression | neProperty(String propertyName, String otherPropertyName) Apply a "not equal" constraint to two properties |
Criterion | not(Criterion expression) Return the negation of an expression |
LogicalExpression | or(Criterion lhs, Criterion rhs) Return the disjuction of two expressions |
Disjunction | or(Criterion... predicates) Return the disjuction of multiple expressions |
Criterion | sizeEq(String propertyName, int size) Constrain a collection valued property by size |
Criterion | sizeGe(String propertyName, int size) Constrain a collection valued property by size |
Criterion | sizeGt(String propertyName, int size) Constrain a collection valued property by size |
Criterion | sizeLe(String propertyName, int size) Constrain a collection valued property by size |
Criterion | sizeLt(String propertyName, int size) Constrain a collection valued property by size |
Criterion | sizeNe(String propertyName, int size) Constrain a collection valued property by size |
Criterion | sqlRestriction(String sql) Apply a constraint expressed in SQL with no JDBC parameters. |
Criterion | sqlRestriction(String sql, Object[] values, Type[] types) Create a restriction expressed in SQL with JDBC parameters. |
Criterion | sqlRestriction(String sql, Object value, Type type) Create a restriction expressed in SQL with one JDBC parameter. |