Class ModelAttributesValueResolver<T extends ItemModel>

  • All Implemented Interfaces:
    QualifierProviderAware, ValueResolver<T>
    Direct Known Subclasses:
    ProductAttributesValueResolver

    public class ModelAttributesValueResolver<T extends ItemModel>
    extends AbstractValueResolver<T,​java.lang.Object,​java.lang.Object>
    Resolver that gets the values from attributes on the model. By default, if parameter attribute is not specified, it tries to get the attribute with the same name as the one configured on the indexed property.

    Supported parameters:

    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 FieldValueProviderException is 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