/** * Creates a "not equals" Criterion based on the specified property name and value. * * @param propertyName The property name * @param propertyValue The property value * @return A Criterion instance */ public Criteria ne(String propertyName, Object propertyValue) { validatePropertyName(propertyName, "ne"); addToCriteria(Restrictions.ne(propertyName, propertyValue)); return this; }
@Override public Query.Criterion createCriterion() { return Restrictions.ne(propertyName, arguments[0]); }