Class EnumPropertyValueExtractor
java.lang.Object
io.jmix.search.index.mapping.propertyvalue.impl.AbstractPropertyValueExtractor
io.jmix.search.index.mapping.propertyvalue.impl.EnumPropertyValueExtractor
- All Implemented Interfaces:
PropertyValueExtractor
@Component("search_EnumPropertyValueExtractor")
public class EnumPropertyValueExtractor
extends AbstractPropertyValueExtractor
-
Field Summary
FieldsFields inherited from class io.jmix.search.index.mapping.propertyvalue.impl.AbstractPropertyValueExtractor
objectMapper -
Constructor Summary
ConstructorsConstructorDescriptionEnumPropertyValueExtractor(Messages messages, CoreProperties coreProperties) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanisSupported(Object entity, MetaPropertyPath propertyPath, Map<String, Object> parameters) Checks if this value mapper supports value extraction of provided property.protected com.fasterxml.jackson.databind.JsonNodetransformMultipleValues(Iterable<?> values, Map<String, Object> parameters) Transform extracted value of multi-value property into result json.protected com.fasterxml.jackson.databind.JsonNodetransformSingleValue(Object value, Map<String, Object> parameters) Transform extracted value of single-value property into result json.Methods inherited from class io.jmix.search.index.mapping.propertyvalue.impl.AbstractPropertyValueExtractor
getFlatValueOrNull, getValue, isCollection, processValue
-
Field Details
-
messages
-
coreProperties
-
-
Constructor Details
-
EnumPropertyValueExtractor
-
-
Method Details
-
isSupported
protected boolean isSupported(Object entity, MetaPropertyPath propertyPath, Map<String, Object> parameters) Description copied from class:AbstractPropertyValueExtractorChecks if this value mapper supports value extraction of provided property.- Specified by:
isSupportedin classAbstractPropertyValueExtractor- Parameters:
entity- instancepropertyPath- propertyparameters- parameters- Returns:
- true if value mapper supports this property, false otherwise
-
transformSingleValue
protected com.fasterxml.jackson.databind.JsonNode transformSingleValue(Object value, Map<String, Object> parameters) Description copied from class:AbstractPropertyValueExtractorTransform extracted value of single-value property into result json.- Specified by:
transformSingleValuein classAbstractPropertyValueExtractor- Parameters:
value- value of single-value propertyparameters- parameters- Returns:
- value as json
-
transformMultipleValues
protected com.fasterxml.jackson.databind.JsonNode transformMultipleValues(Iterable<?> values, Map<String, Object> parameters) Description copied from class:AbstractPropertyValueExtractorTransform extracted value of multi-value property into result json.- Specified by:
transformMultipleValuesin classAbstractPropertyValueExtractor- Parameters:
values- values of multi-value propertyparameters- parameters- Returns:
- value as json
-