Package de.otto.synapse.messagestore
Class CalculatedValueIndexer
java.lang.Object
de.otto.synapse.messagestore.CalculatedValueIndexer
- All Implemented Interfaces:
Indexer
-
Constructor Summary
ConstructorsConstructorDescriptionCalculatedValueIndexer(Index index, Function<MessageStoreEntry, String> calculator) Creates aCalculatedValueIndexer. -
Method Summary
Modifier and TypeMethodDescriptioncalc(Index index, MessageStoreEntry entry) Calculates the Index value from the message-store entry.com.google.common.collect.ImmutableSet<Index>Returns the indexes supported by this Indexer.index(MessageStoreEntry entry) boolean
-
Constructor Details
-
CalculatedValueIndexer
public CalculatedValueIndexer(@Nonnull Index index, @Nonnull Function<MessageStoreEntry, String> calculator) Creates aCalculatedValueIndexer.- Parameters:
index- theIndexthat is calculated by thecalculatorfunctioncalculator- the function that is used to calculate the value for the index
-
-
Method Details
-
getIndexes
Description copied from interface:IndexerReturns the indexes supported by this Indexer.- Specified by:
getIndexesin interfaceIndexer- Returns:
- Set of Index instances
-
supports
-
calc
Description copied from interface:IndexerCalculates the Index value from the message-store entry. -
index
-