public class ModelAttributesValueResolver<T extends ItemModel> extends AbstractValueResolver<T,java.lang.Object,java.lang.Object>
Parameter Default value Description optional true If false, indicates that the resolved values should not be null and not an empty string (for every qualifier). If these conditions are not met, an exception of type FieldValueProviderExceptionis thrown.attribute If specified, this is the name of the attribute. split false If true, splits any resolved value around matches of a regular expression (only if the value is of type String). splitRegex \s+ If split is true this is the regular expression to use. format null The ID of the Format Bean that is going to be used to format the attribute value object before applying the split evaluateExpression false If true the attribute name is assumed to be a spring expression language that need to be evaluated
AbstractValueResolver.ValueResolverContext<T,U>| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ATTRIBUTE_PARAM |
static java.lang.String |
ATTRIBUTE_PARAM_DEFAULT_VALUE |
static java.lang.String |
EVALUATE_EXPRESSION_PARAM |
static boolean |
EVALUATE_EXPRESSION_PARAM_DEFAULT_VALUE |
static java.lang.String |
OPTIONAL_PARAM |
static boolean |
OPTIONAL_PARAM_DEFAULT_VALUE |
| Constructor and Description |
|---|
ModelAttributesValueResolver() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addFieldValues(InputDocument document,
IndexerBatchContext batchContext,
IndexedProperty indexedProperty,
T model,
AbstractValueResolver.ValueResolverContext<java.lang.Object,java.lang.Object> resolverContext) |
protected java.lang.String |
getAttributeName(IndexedProperty indexedProperty) |
protected java.lang.Object |
getAttributeValue(IndexedProperty indexedProperty,
T model,
java.lang.String attributeName) |
ExpressionEvaluator |
getExpressionEvaluator() |
ModelService |
getModelService() |
TypeService |
getTypeService() |
void |
setExpressionEvaluator(ExpressionEvaluator expressionEvaluator) |
void |
setModelService(ModelService modelService) |
void |
setTypeService(TypeService typeService) |
addFieldValue, createLocalSessionContext, doResolve, filterAndAddFieldValues, filterFieldValue, getQualifierProvider, getSessionService, getValueFilters, loadData, loadQualifierData, removeLocalSessionContext, resolve, setQualifierProvider, setSessionService, setValueFilterspublic static final java.lang.String OPTIONAL_PARAM
public static final boolean OPTIONAL_PARAM_DEFAULT_VALUE
public static final java.lang.String ATTRIBUTE_PARAM
public static final java.lang.String ATTRIBUTE_PARAM_DEFAULT_VALUE
public static final java.lang.String EVALUATE_EXPRESSION_PARAM
public static final boolean EVALUATE_EXPRESSION_PARAM_DEFAULT_VALUE
public ModelService getModelService()
public void setModelService(ModelService modelService)
public TypeService getTypeService()
public void setTypeService(TypeService typeService)
public ExpressionEvaluator getExpressionEvaluator()
public void setExpressionEvaluator(ExpressionEvaluator expressionEvaluator)
protected void addFieldValues(InputDocument document, IndexerBatchContext batchContext, IndexedProperty indexedProperty, T model, AbstractValueResolver.ValueResolverContext<java.lang.Object,java.lang.Object> resolverContext) throws FieldValueProviderException
addFieldValues in class AbstractValueResolver<T extends ItemModel,java.lang.Object,java.lang.Object>FieldValueProviderExceptionprotected java.lang.String getAttributeName(IndexedProperty indexedProperty)
protected java.lang.Object getAttributeValue(IndexedProperty indexedProperty, T model, java.lang.String attributeName) throws FieldValueProviderException
FieldValueProviderExceptionCopyright © 2018 SAP SE. All Rights Reserved.