public class RegisteredLookupExtractionFn extends Object implements ExtractionFn
ExtractionFn.ExtractionType| Constructor and Description |
|---|
RegisteredLookupExtractionFn(LookupReferencesManager manager,
String lookup,
boolean retainMissingValue,
String replaceMissingValueWith,
boolean injective,
Boolean optimize) |
| Modifier and Type | Method and Description |
|---|---|
String |
apply(long value)
The "extraction" function.
|
String |
apply(Object value)
The "extraction" function.
|
String |
apply(String value)
The "extraction" function.
|
boolean |
equals(Object o) |
byte[] |
getCacheKey()
Returns a byte[] unique to all concrete implementations of DimExtractionFn.
|
ExtractionFn.ExtractionType |
getExtractionType()
A dim extraction can be of one of two types, renaming or rebucketing.
|
String |
getLookup() |
String |
getReplaceMissingValueWith() |
int |
hashCode() |
boolean |
isInjective() |
boolean |
isOptimize() |
boolean |
isRetainMissingValue() |
boolean |
preservesOrdering()
Offers information on whether the extraction will preserve the original ordering of the values.
|
String |
toString() |
public RegisteredLookupExtractionFn(LookupReferencesManager manager, String lookup, boolean retainMissingValue, @Nullable String replaceMissingValueWith, boolean injective, Boolean optimize)
public String getLookup()
public boolean isRetainMissingValue()
public String getReplaceMissingValueWith()
public boolean isInjective()
public boolean isOptimize()
public byte[] getCacheKey()
ExtractionFngetCacheKey in interface ExtractionFnpublic String apply(Object value)
ExtractionFnIn order to maintain the "null and empty string are equivalent" semantics that Druid provides, the empty string is considered invalid output for this method and should instead return null. This is a contract on the method rather than enforced at a lower level in order to eliminate a global check for extraction functions that do not already need one.
apply in interface ExtractionFnvalue - the original value of the dimensionpublic String apply(String value)
ExtractionFn
Like ExtractionFn.apply(Object), the empty string is considered invalid output for this method and it should
instead return null.
apply in interface ExtractionFnvalue - the original value of the dimensionpublic String apply(long value)
ExtractionFn
Like ExtractionFn.apply(Object), the empty string is considered invalid output for this method and it should
instead return null.
apply in interface ExtractionFnvalue - the original value of the dimensionpublic boolean preservesOrdering()
ExtractionFnSome optimizations of queries is possible if ordering is preserved. Null values *do* count towards ordering.
preservesOrdering in interface ExtractionFnpublic ExtractionFn.ExtractionType getExtractionType()
ExtractionFngetExtractionType in interface ExtractionFnExtractionFn.ExtractionType declaring what kind of manipulation this
function doesCopyright © 2011–2017. All rights reserved.