Package de.cxp.ocs.spi.indexer
Interface DocumentPreProcessor
- All Known Implementing Classes:
AsciiFoldingDataProcessor,AttributeToDataFieldConverter,ConfigureableDataprocessor,ExtractCategoryLevelDataProcessor,FlagFieldDataProcessor,RemoveFieldContentDelimiterProcessor,RemoveValuesDataProcessor,ReplacePatternInValuesDataProcessor,SkipDocumentDataProcessor,SplitValueDataProcessor,WordSplitterDataProcessor
public interface DocumentPreProcessor
DocumentPreProcessor implementations can be used to alter product
data before they get transformed into
IndexableItems.
Several implementations can be configured to run one after another, where
each processor get's the manipulated record value of the former processor.- Author:
- hjk, rb
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidfinish(boolean success) optional callback about pre-processing done for all documentsvoidinitialize(FieldConfigAccess fieldConfig, Map<String, String> preProcessorConfig) DataPreProcessor MUST have a no-args constructor.booleanCalled for each source document.
-
Method Details
-
initialize
DataPreProcessor MUST have a no-args constructor. To configure it afterwards, this method will be used.- Parameters:
fieldConfig- field config accesspreProcessorConfig- custom string-to-string map that can be configured per DocumentPreProcessor.
-
process
Called for each source document.- Parameters:
sourceDocument- source documentvisible- weather or not the record is currently marked for indexing.- Returns:
trueif the record should be indexed,falseotherwise.
-
finish
default void finish(boolean success) optional callback about pre-processing done for all documents- Parameters:
success- true if a complete indexing was finished successfully or not.
-