Package com.exasol.sql.expression
Class Like
- java.lang.Object
-
- com.exasol.util.AbstractTree
-
- com.exasol.util.AbstractBottomUpTreeNode
-
- com.exasol.sql.expression.AbstractBooleanExpression
-
- com.exasol.sql.expression.Like
-
- All Implemented Interfaces:
BooleanExpression,ValueExpression,TreeNode
public class Like extends AbstractBooleanExpression
This class represents a logical LIKE predicate.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classLike.BuilderA builder forLike.
-
Field Summary
-
Fields inherited from class com.exasol.util.AbstractTree
children, parent
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidacceptConcrete(BooleanExpressionVisitor visitor)Sub-classes must override this method so that the visitor knows the type of the visited class at compile time.static Like.Builderbuilder()Create a new builder forLike.voiddismissConcrete(BooleanExpressionVisitor visitor)Sub-classes must override this method so that the visitor knows the type of the visited class at compile time.CharactergetEscape()Get an escape character.ValueExpressiongetLeftOperand()Get the left-hand side operator.ValueExpressiongetRightOperand()Get the right-hand side operator.booleanhasEscape()Check if LIKE predicate has ESCAPE.booleanhasNot()Check if LIKE predicate has NOT.-
Methods inherited from class com.exasol.sql.expression.AbstractBooleanExpression
accept, accept
-
Methods inherited from class com.exasol.util.AbstractBottomUpTreeNode
addChild, getRoot, setParent
-
Methods inherited from class com.exasol.util.AbstractTree
getChild, getChildren, getParent, isChild, isFirstSibling, isRoot, isSibling
-
-
-
-
Method Detail
-
builder
public static Like.Builder builder()
Create a new builder forLike.- Returns:
- new
Like.Builder
-
getLeftOperand
public ValueExpression getLeftOperand()
Get the left-hand side operator.- Returns:
- left operator
-
getRightOperand
public ValueExpression getRightOperand()
Get the right-hand side operator.- Returns:
- right operator
-
hasNot
public boolean hasNot()
Check if LIKE predicate has NOT.- Returns:
- true if contains not
-
hasEscape
public boolean hasEscape()
Check if LIKE predicate has ESCAPE.- Returns:
- true if contains not
-
getEscape
public Character getEscape()
Get an escape character.- Returns:
- escape char
-
acceptConcrete
public void acceptConcrete(BooleanExpressionVisitor visitor)
Description copied from class:AbstractBooleanExpressionSub-classes must override this method so that the visitor knows the type of the visited class at compile time.- Specified by:
acceptConcretein classAbstractBooleanExpression- Parameters:
visitor- visitor to accept
-
dismissConcrete
public void dismissConcrete(BooleanExpressionVisitor visitor)
Description copied from class:AbstractBooleanExpressionSub-classes must override this method so that the visitor knows the type of the visited class at compile time.- Specified by:
dismissConcretein classAbstractBooleanExpression- Parameters:
visitor- visitor to accept
-
-