public class LikeOperator extends Operator<org.apache.lucene.util.BytesRef>
Modifier and Type | Field and Description |
---|---|
static char |
DEFAULT_ESCAPE |
static java.lang.String |
NAME |
PREFIX, RETURN_TYPE
Constructor and Description |
---|
LikeOperator(FunctionInfo info) |
Modifier and Type | Method and Description |
---|---|
Scalar<java.lang.Boolean,org.apache.lucene.util.BytesRef> |
compile(java.util.List<Symbol> arguments)
Called to return a "optimized" version of a scalar implementation.
|
java.lang.Boolean |
evaluate(Input<org.apache.lucene.util.BytesRef>... args)
Evaluate the function using the provided arguments
|
FunctionInfo |
info()
Provides meta information about this function implementation.
|
static java.lang.String |
patternToRegex(java.lang.String patternString,
char escapeChar,
boolean shouldEscape) |
static void |
register(OperatorModule module) |
generateInfo, normalizeSymbol, operator
anyNonLiterals, evaluateIfLiterals, withOperator
public static final java.lang.String NAME
public static final char DEFAULT_ESCAPE
public LikeOperator(FunctionInfo info)
public static void register(OperatorModule module)
public FunctionInfo info()
FunctionImplementation
public Scalar<java.lang.Boolean,org.apache.lucene.util.BytesRef> compile(java.util.List<Symbol> arguments)
Scalar
compile
in class Scalar<java.lang.Boolean,org.apache.lucene.util.BytesRef>
arguments
- arguments in symbol form. If any symbols are literals, any arguments passed to
Scalar.evaluate(Input[])
will have the same value as those literals.
(Within the scope of a single operation)public java.lang.Boolean evaluate(Input<org.apache.lucene.util.BytesRef>... args)
Scalar
public static java.lang.String patternToRegex(java.lang.String patternString, char escapeChar, boolean shouldEscape)