Deveel.Data.Sql.Query.RangeSelectNode.RangeSetUpdater.VisitBinary C# (CSharp) Method

VisitBinary() public method

public VisitBinary ( SqlBinaryExpression binaryEpression ) : SqlExpression
binaryEpression Deveel.Data.Sql.Expressions.SqlBinaryExpression
return Deveel.Data.Sql.Expressions.SqlExpression
            public override SqlExpression VisitBinary(SqlBinaryExpression binaryEpression)
            {
                var op = binaryEpression.ExpressionType;

                // Evaluate to an object
                var value = binaryEpression.Right.EvaluateToConstant(context, null);

                // If the evaluated object is not of a comparable type, then it becomes
                // null.
                var fieldType = field.ColumnType;
                if (!value.Type.IsComparable(fieldType))
                    value = Field.Null(fieldType);

                // Intersect this in the range set
                indexRangeSet = indexRangeSet.Intersect(op, value);

                return base.VisitBinary(binaryEpression);
            }
RangeSelectNode.RangeSetUpdater