public class PollingLookup extends LookupExtractor
Modifier and Type | Class and Description |
---|---|
protected static class |
PollingLookup.CacheRefKeeper |
Constructor and Description |
---|
PollingLookup(long pollPeriodMs,
DataFetcher dataFetcher,
PollingCacheFactory cacheFactory) |
Modifier and Type | Method and Description |
---|---|
String |
apply(String key)
Apply a particular lookup methodology to the input string
|
void |
close() |
boolean |
equals(Object o) |
byte[] |
getCacheKey()
Create a cache key for use in results caching
|
int |
hashCode() |
boolean |
isOpen() |
List<String> |
unapply(String value)
Provide the reverse mapping from a given value to a list of keys
|
applyAll, isOneToOne, unapplyAll
public PollingLookup(long pollPeriodMs, DataFetcher dataFetcher, PollingCacheFactory cacheFactory)
public void close()
public String apply(@NotNull String key)
LookupExtractor
apply
in class LookupExtractor
key
- The value to apply the lookup to. May not be nullpublic List<String> unapply(String value)
LookupExtractor
unapply
in class LookupExtractor
value
- the value to apply the reverse lookup
Null and empty are considered to be the same value = nullToEmpty(value)public byte[] getCacheKey()
LookupExtractor
getCacheKey
in class LookupExtractor
public boolean isOpen()
Copyright © 2011–2017. All rights reserved.