use of org.drools.core.spi.FieldValue in project drools by kiegroup.
the class ReteTesterHelper method getLiteralConstraint.
public AlphaNodeFieldConstraint getLiteralConstraint(final Pattern pattern, final String fieldName, final String evaluatorString, final String value) {
final Class<?> clazz = ((ClassObjectType) pattern.getObjectType()).getClassType();
final InternalReadAccessor extractor = store.getReader(clazz, fieldName);
FieldValue fieldValue = FieldFactory.getInstance().getFieldValue(value, extractor.getValueType());
return new MvelConstraintTestUtil(fieldName + evaluatorString + value, fieldValue, extractor);
}
Aggregations