Interface AttributesGroupConfiguration
- All Known Implementing Classes:
AbstractAttributesGroupConfiguration,DynamicAttributesGroupConfiguration,StaticAttributesGroupConfiguration
This interface allows specifying either a FieldMappingStrategy implementation (as a class or instance)
or an explicit field configuration to control the mapping process. Additional customization can be achieved
through property value extractors and parameters.
-
Method Summary
Modifier and TypeMethodDescription@Nullable FieldConfigurationProvides explicit configuration for indexed fields.@Nullable FieldMappingStrategyProvidesFieldMappingStrategyinstance that should be used to map properties.@Nullable Class<? extends FieldMappingStrategy> ProvidesFieldMappingStrategyimplementation class that should be used to map properties.@Nullable IntegergetOrder()Provides explicit order.Provides additional parameters related to this element.@Nullable PropertyValueExtractorProvides explicit property value extractor.
-
Method Details
-
getFieldMappingStrategyClass
@Nullable Class<? extends FieldMappingStrategy> getFieldMappingStrategyClass()ProvidesFieldMappingStrategyimplementation class that should be used to map properties.Can be null if strategy is defined as instance (see
getFieldMappingStrategy()) or configuration is specified explicitly (seegetFieldConfiguration())- Returns:
FieldMappingStrategyimplementation class
-
getFieldMappingStrategy
@Nullable FieldMappingStrategy getFieldMappingStrategy()ProvidesFieldMappingStrategyinstance that should be used to map properties.Can be null if strategy is defined as class (see
getFieldMappingStrategyClass()) or configuration is specified explicitly (seegetFieldConfiguration())AbstractAttributesGroupConfiguration.getFieldMappingStrategyClass()is ignored if this instance is set.- Returns:
FieldMappingStrategyinstance
-
getFieldConfiguration
@Nullable FieldConfiguration getFieldConfiguration()Provides explicit configuration for indexed fields.Can be null if strategy is defined as class (see
getFieldMappingStrategyClass()) or instance (seegetFieldMappingStrategy()).If strategy (as class or instance) and explicit configuration are both set then explicit configuration will override matching parameters of configuration generated by strategy.
- Returns:
- field configuration
-
getPropertyValueExtractor
@Nullable PropertyValueExtractor getPropertyValueExtractor()Provides explicit property value extractor.Can be null if strategy is defined as class (see
getFieldMappingStrategyClass()) or instance (seegetFieldMappingStrategy()).Property value extractor got from strategy will be ignored if explicit one is set.
- Returns:
- property value extractor
-
getParameters
Provides additional parameters related to this element.Parameters are used by
FieldMapperduring mapping generation withinFieldMappingStrategy(e.g. analyzer) or byPropertyValueExtractorat runtime (e.g. enable\disable indexing file content).- Returns:
- Map with parameters
-
getOrder
@Nullable Integer getOrder()Provides explicit order.- Returns:
- order
-