Class IndexExpression
- java.lang.Object
-
- dev.morphia.aggregation.expressions.impls.Expression
-
- dev.morphia.aggregation.expressions.impls.IndexExpression
-
public class IndexExpression extends Expression
Defines the $indexOfBytes expression- Since:
- 2.0
-
-
Constructor Summary
Constructors Constructor Description IndexExpression(String operation, Expression string, Expression substring)Creates the new expression
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidencode(Datastore datastore, BsonWriter writer, EncoderContext encoderContext)IndexExpressionend(int end)Sets the end boundary for searchingIndexExpressionstart(int start)Sets the start boundary for searching-
Methods inherited from class dev.morphia.aggregation.expressions.impls.Expression
getOperation, getValue, toString
-
-
-
-
Constructor Detail
-
IndexExpression
@MorphiaInternal public IndexExpression(String operation, Expression string, Expression substring)
Creates the new expression- Parameters:
operation- the index operation namestring- the string to searchsubstring- the target string
Developer note.This is an internal item. Its function and presence are subject to change without warning. Its use is highly discouraged.
-
-
Method Detail
-
encode
public void encode(Datastore datastore, BsonWriter writer, EncoderContext encoderContext)
- Overrides:
encodein classExpression- Parameters:
datastore- the datastorewriter- the writerencoderContext- the context
-
end
public IndexExpression end(int end)
Sets the end boundary for searching- Parameters:
end- the end- Returns:
- this
-
start
public IndexExpression start(int start)
Sets the start boundary for searching- Parameters:
start- the start- Returns:
- this
-
-