Package org.hibernate.criterion
Class AbstractEmptinessExpression
- java.lang.Object
-
- org.hibernate.criterion.AbstractEmptinessExpression
-
- All Implemented Interfaces:
java.io.Serializable,Criterion
- Direct Known Subclasses:
EmptyExpression,NotEmptyExpression
public abstract class AbstractEmptinessExpression extends java.lang.Object implements Criterion
Base expression implementation for (not) emptiness checking of collection properties- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.StringpropertyName
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractEmptinessExpression(java.lang.String propertyName)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract booleanexcludeEmpty()Should empty rows be excluded?protected QueryableCollectiongetQueryableCollection(java.lang.String entityName, java.lang.String propertyName, SessionFactoryImplementor factory)TypedValue[]getTypedValues(Criteria criteria, CriteriaQuery criteriaQuery)Return typed values for all parameters in the rendered SQL fragmentjava.lang.StringtoSqlString(Criteria criteria, CriteriaQuery criteriaQuery)Render the SQL fragmentjava.lang.StringtoString()
-
-
-
Method Detail
-
excludeEmpty
protected abstract boolean excludeEmpty()
Should empty rows be excluded?- Returns:
trueIndicates the expression should 'exists';falseindicates 'not exists'
-
toSqlString
public final java.lang.String toSqlString(Criteria criteria, CriteriaQuery criteriaQuery) throws HibernateException
Description copied from interface:CriterionRender the SQL fragment- Specified by:
toSqlStringin interfaceCriterion- Parameters:
criteria- The local criteriacriteriaQuery- The overall criteria query- Returns:
- The generated SQL fragment
- Throws:
HibernateException- Problem during rendering.
-
getQueryableCollection
protected QueryableCollection getQueryableCollection(java.lang.String entityName, java.lang.String propertyName, SessionFactoryImplementor factory) throws HibernateException
- Throws:
HibernateException
-
getTypedValues
public final TypedValue[] getTypedValues(Criteria criteria, CriteriaQuery criteriaQuery) throws HibernateException
Description copied from interface:CriterionReturn typed values for all parameters in the rendered SQL fragment- Specified by:
getTypedValuesin interfaceCriterion- Parameters:
criteria- The local criteriacriteriaQuery- The overall criteria query- Returns:
- The types values (for binding)
- Throws:
HibernateException- Problem determining types.
-
toString
public final java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-