use of com.evolveum.midpoint.repo.sql.query.matcher.Matcher in project midpoint by Evolveum.
the class ItemValueRestriction method createPropertyVsConstantCondition.
Condition createPropertyVsConstantCondition(String hqlPropertyPath, Object value, ValueFilter filter) throws QueryException {
ItemRestrictionOperation operation = findOperationForFilter(filter);
InterpretationContext context = getContext();
QueryInterpreter interpreter = context.getInterpreter();
Matcher matcher = interpreter.findMatcher(value);
String matchingRule = filter.getMatchingRule() != null ? filter.getMatchingRule().getLocalPart() : null;
// noinspection unchecked
return matcher.match(context.getHibernateQuery(), operation, hqlPropertyPath, value, matchingRule);
}
Aggregations