expression

package
v0.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnyExpr added in v0.11.0

type AnyExpr struct {
	// contains filtered or unexported fields
}

AnyExpr represents the ANY/SOME expression.

func NewAnyExpr added in v0.11.0

func NewAnyExpr(subOperator string) *AnyExpr

NewAnyExpr creates a new AnyExpr expression.

func NewSomeExpr added in v0.11.0

func NewSomeExpr(subOperator string) *AnyExpr

NewSomeExpr creates a new AnyExpr expression for SOME. SOME is synonymous with ANY.

func (*AnyExpr) Children added in v0.11.0

func (a *AnyExpr) Children() []sql.Expression

Children implements the Expression interface.

func (*AnyExpr) DebugString added in v0.11.0

func (a *AnyExpr) DebugString() string

DebugString implements the Expression interface.

func (*AnyExpr) Eval added in v0.11.0

func (a *AnyExpr) Eval(ctx *sql.Context, row sql.Row) (interface{}, error)

Eval implements the Expression interface.

func (*AnyExpr) IsNullable added in v0.11.0

func (a *AnyExpr) IsNullable() bool

IsNullable implements the Expression interface.

func (*AnyExpr) Resolved added in v0.11.0

func (a *AnyExpr) Resolved() bool

Resolved implements the Expression interface.

func (*AnyExpr) String added in v0.11.0

func (a *AnyExpr) String() string

String implements the fmt.Stringer interface.

func (*AnyExpr) Type added in v0.11.0

func (a *AnyExpr) Type() sql.Type

Type implements the Expression interface.

func (*AnyExpr) WithChildren added in v0.11.0

func (a *AnyExpr) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the Expression interface.

func (*AnyExpr) WithResolvedChildren added in v0.11.0

func (a *AnyExpr) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the Expression interface.

type Array

type Array struct {
	// contains filtered or unexported fields
}

Array represents an ARRAY[...] expression.

func NewArray

func NewArray(coercedType sql.Type) (*Array, error)

NewArray returns a new *Array.

func (*Array) Children

func (array *Array) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*Array) Eval

func (array *Array) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*Array) IsNullable

func (array *Array) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*Array) Resolved

func (array *Array) Resolved() bool

Resolved implements the sql.Expression interface.

func (*Array) String

func (array *Array) String() string

String implements the sql.Expression interface.

func (*Array) Type

func (array *Array) Type() sql.Type

Type implements the sql.Expression interface.

func (*Array) WithChildren

func (array *Array) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*Array) WithResolvedChildren

func (array *Array) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type AssignmentCast added in v0.8.0

type AssignmentCast struct {
	// contains filtered or unexported fields
}

AssignmentCast handles assignment casts.

func NewAssignmentCast added in v0.8.0

func NewAssignmentCast(expr sql.Expression, fromType pgtypes.DoltgresType, toType pgtypes.DoltgresType) *AssignmentCast

NewAssignmentCast returns a new *AssignmentCast expression.

func (*AssignmentCast) Children added in v0.8.0

func (ac *AssignmentCast) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*AssignmentCast) Eval added in v0.8.0

func (ac *AssignmentCast) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*AssignmentCast) IsNullable added in v0.8.0

func (ac *AssignmentCast) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*AssignmentCast) Resolved added in v0.8.0

func (ac *AssignmentCast) Resolved() bool

Resolved implements the sql.Expression interface.

func (*AssignmentCast) String added in v0.8.0

func (ac *AssignmentCast) String() string

String implements the sql.Expression interface.

func (*AssignmentCast) Type added in v0.8.0

func (ac *AssignmentCast) Type() sql.Type

Type implements the sql.Expression interface.

func (*AssignmentCast) WithChildren added in v0.8.0

func (ac *AssignmentCast) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

type BinaryOperator added in v0.5.0

type BinaryOperator struct {
	// contains filtered or unexported fields
}

BinaryOperator represents a VALUE OPERATOR VALUE expression.

func NewBinaryOperator added in v0.5.0

func NewBinaryOperator(operator framework.Operator) *BinaryOperator

NewBinaryOperator returns a new *BinaryOperator.

func (*BinaryOperator) Children added in v0.5.0

func (b *BinaryOperator) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*BinaryOperator) Eval added in v0.5.0

func (b *BinaryOperator) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*BinaryOperator) IsNullable added in v0.5.0

func (b *BinaryOperator) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*BinaryOperator) Left added in v0.5.0

func (b *BinaryOperator) Left() sql.Expression

Left implements the expression.BinaryExpression interface.

func (*BinaryOperator) Operator added in v0.10.0

func (b *BinaryOperator) Operator() framework.Operator

Operator returns the operator that is used.

func (*BinaryOperator) RepresentsEquality added in v0.12.0

func (b *BinaryOperator) RepresentsEquality() bool

RepresentsEquality implements the expression.Equality interface.

func (*BinaryOperator) Resolved added in v0.5.0

func (b *BinaryOperator) Resolved() bool

Resolved implements the sql.Expression interface.

func (*BinaryOperator) Right added in v0.5.0

func (b *BinaryOperator) Right() sql.Expression

Right implements the expression.BinaryExpression interface.

func (*BinaryOperator) String added in v0.5.0

func (b *BinaryOperator) String() string

String implements the sql.Expression interface.

func (*BinaryOperator) SwapParameters added in v0.12.0

func (b *BinaryOperator) SwapParameters(ctx *sql.Context) (expression.Equality, error)

SwapParameters implements the expression.Equality interface.

func (*BinaryOperator) ToComparer added in v0.12.0

func (b *BinaryOperator) ToComparer() (expression.Comparer, error)

ToComparer implements the expression.Equality interface.

func (*BinaryOperator) Type added in v0.5.0

func (b *BinaryOperator) Type() sql.Type

Type implements the sql.Expression interface.

func (*BinaryOperator) WithChildren added in v0.5.0

func (b *BinaryOperator) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*BinaryOperator) WithResolvedChildren added in v0.5.0

func (b *BinaryOperator) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type ExplicitCast added in v0.8.0

type ExplicitCast struct {
	// contains filtered or unexported fields
}

ExplicitCast represents a VALUE::TYPE expression.

func NewExplicitCast added in v0.8.0

func NewExplicitCast(expr sql.Expression, toType pgtypes.DoltgresType) *ExplicitCast

NewExplicitCast returns a new *ExplicitCast expression.

func NewExplicitCastInjectable added in v0.10.0

func NewExplicitCastInjectable(castToType sql.Type) (*ExplicitCast, error)

NewExplicitCastInjectable returns an incomplete *ExplicitCast that must be resolved through the vitess.Injectable interface.

func (*ExplicitCast) Child added in v0.8.0

func (c *ExplicitCast) Child() sql.Expression

Child returns the child that is being cast.

func (*ExplicitCast) Children added in v0.8.0

func (c *ExplicitCast) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*ExplicitCast) Eval added in v0.8.0

func (c *ExplicitCast) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*ExplicitCast) IsNullable added in v0.8.0

func (c *ExplicitCast) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*ExplicitCast) Resolved added in v0.8.0

func (c *ExplicitCast) Resolved() bool

Resolved implements the sql.Expression interface.

func (*ExplicitCast) String added in v0.8.0

func (c *ExplicitCast) String() string

String implements the sql.Expression interface.

func (*ExplicitCast) Type added in v0.8.0

func (c *ExplicitCast) Type() sql.Type

Type implements the sql.Expression interface.

func (*ExplicitCast) WithChildren added in v0.8.0

func (c *ExplicitCast) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*ExplicitCast) WithResolvedChildren added in v0.8.0

func (c *ExplicitCast) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type GMSCast added in v0.8.0

type GMSCast struct {
	// contains filtered or unexported fields
}

GMSCast handles the conversion from a GMS expression's type to its Doltgres type that is most similar.

func NewGMSCast added in v0.8.0

func NewGMSCast(child sql.Expression) *GMSCast

NewGMSCast returns a new *GMSCast.

func (*GMSCast) Child added in v0.8.0

func (c *GMSCast) Child() sql.Expression

Child returns the child that is being cast.

func (*GMSCast) Children added in v0.8.0

func (c *GMSCast) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*GMSCast) DoltgresType added in v0.8.0

func (c *GMSCast) DoltgresType() pgtypes.DoltgresType

DoltgresType returns the DoltgresType that the cast evaluates to. This is the same value that is returned by Type().

func (*GMSCast) Eval added in v0.8.0

func (c *GMSCast) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*GMSCast) IsNullable added in v0.8.0

func (c *GMSCast) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*GMSCast) Resolved added in v0.8.0

func (c *GMSCast) Resolved() bool

Resolved implements the sql.Expression interface.

func (*GMSCast) String added in v0.8.0

func (c *GMSCast) String() string

String implements the sql.Expression interface.

func (*GMSCast) Type added in v0.8.0

func (c *GMSCast) Type() sql.Type

Type implements the sql.Expression interface.

func (*GMSCast) WithChildren added in v0.8.0

func (c *GMSCast) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

type ImplicitCast added in v0.8.0

type ImplicitCast struct {
	// contains filtered or unexported fields
}

ImplicitCast handles implicit casts.

func NewImplicitCast added in v0.8.0

func NewImplicitCast(expr sql.Expression, fromType pgtypes.DoltgresType, toType pgtypes.DoltgresType) *ImplicitCast

NewImplicitCast returns a new *ImplicitCast expression.

func (*ImplicitCast) Children added in v0.8.0

func (ic *ImplicitCast) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*ImplicitCast) Eval added in v0.8.0

func (ic *ImplicitCast) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*ImplicitCast) IsNullable added in v0.8.0

func (ic *ImplicitCast) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*ImplicitCast) Resolved added in v0.8.0

func (ic *ImplicitCast) Resolved() bool

Resolved implements the sql.Expression interface.

func (*ImplicitCast) String added in v0.8.0

func (ic *ImplicitCast) String() string

String implements the sql.Expression interface.

func (*ImplicitCast) Type added in v0.8.0

func (ic *ImplicitCast) Type() sql.Type

Type implements the sql.Expression interface.

func (*ImplicitCast) WithChildren added in v0.8.0

func (ic *ImplicitCast) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

type InSubquery added in v0.11.1

type InSubquery struct {
	// contains filtered or unexported fields
}

InSubquery represents a VALUE IN (SELECT ...) expression.

func NewInSubquery added in v0.11.1

func NewInSubquery() *InSubquery

NewInSubquery returns a new *InSubquery.

func (*InSubquery) Children added in v0.11.1

func (in *InSubquery) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*InSubquery) Eval added in v0.11.1

func (in *InSubquery) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*InSubquery) IsNullable added in v0.11.1

func (in *InSubquery) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*InSubquery) Left added in v0.11.1

func (in *InSubquery) Left() sql.Expression

Left implements the expression.BinaryExpression interface.

func (*InSubquery) Resolved added in v0.11.1

func (in *InSubquery) Resolved() bool

Resolved implements the sql.Expression interface.

func (*InSubquery) Right added in v0.11.1

func (in *InSubquery) Right() sql.Expression

Right implements the expression.BinaryExpression interface.

func (*InSubquery) String added in v0.11.1

func (in *InSubquery) String() string

String implements the sql.Expression interface.

func (*InSubquery) Type added in v0.11.1

func (in *InSubquery) Type() sql.Type

Type implements the sql.Expression interface.

func (*InSubquery) WithChildren added in v0.11.1

func (in *InSubquery) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*InSubquery) WithResolvedChildren added in v0.11.1

func (in *InSubquery) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type InTuple added in v0.8.0

type InTuple struct {
	// contains filtered or unexported fields
}

InTuple represents a VALUE IN (<VALUES>) expression.

func NewInTuple added in v0.8.0

func NewInTuple() *InTuple

NewInTuple returns a new *InTuple.

func (*InTuple) Children added in v0.8.0

func (it *InTuple) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*InTuple) Decay added in v0.12.0

func (it *InTuple) Decay() sql.Expression

Decay returns the expression as a series of OR expressions. The behavior is not the same, however it allows some paths to simplify their expression handling (such as filters).

func (*InTuple) Eval added in v0.8.0

func (it *InTuple) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*InTuple) IsNullable added in v0.8.0

func (it *InTuple) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*InTuple) Left added in v0.8.0

func (it *InTuple) Left() sql.Expression

Left implements the expression.BinaryExpression interface.

func (*InTuple) Resolved added in v0.8.0

func (it *InTuple) Resolved() bool

Resolved implements the sql.Expression interface.

func (*InTuple) Right added in v0.8.0

func (it *InTuple) Right() sql.Expression

Right implements the expression.BinaryExpression interface.

func (*InTuple) String added in v0.8.0

func (it *InTuple) String() string

String implements the sql.Expression interface.

func (*InTuple) Type added in v0.8.0

func (it *InTuple) Type() sql.Type

Type implements the sql.Expression interface.

func (*InTuple) WithChildren added in v0.8.0

func (it *InTuple) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*InTuple) WithResolvedChildren added in v0.8.0

func (it *InTuple) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type JoinComparator added in v0.12.0

type JoinComparator struct {
	// contains filtered or unexported fields
}

JoinComparator is specifically for handling how GMS implements joins by implementing expression.Comparer over binary operators.

func NewJoinComparator added in v0.12.0

func NewJoinComparator(eq *BinaryOperator) (*JoinComparator, error)

NewJoinComparator returns a new *JoinComparator.

func (*JoinComparator) Children added in v0.12.0

func (j *JoinComparator) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*JoinComparator) Compare added in v0.12.0

func (j *JoinComparator) Compare(ctx *sql.Context, row sql.Row) (int, error)

Compare implements the expression.Comparer interface.

func (*JoinComparator) Eval added in v0.12.0

func (j *JoinComparator) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*JoinComparator) IsNullable added in v0.12.0

func (j *JoinComparator) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*JoinComparator) Left added in v0.12.0

func (j *JoinComparator) Left() sql.Expression

Left implements the expression.BinaryExpression interface.

func (*JoinComparator) RepresentsEquality added in v0.12.0

func (j *JoinComparator) RepresentsEquality() bool

RepresentsEquality implements the expression.Equality interface.

func (*JoinComparator) Resolved added in v0.12.0

func (j *JoinComparator) Resolved() bool

Resolved implements the sql.Expression interface.

func (*JoinComparator) Right added in v0.12.0

func (j *JoinComparator) Right() sql.Expression

Right implements the expression.BinaryExpression interface.

func (*JoinComparator) String added in v0.12.0

func (j *JoinComparator) String() string

String implements the sql.Expression interface.

func (*JoinComparator) SwapParameters added in v0.12.0

func (j *JoinComparator) SwapParameters(ctx *sql.Context) (expression.Equality, error)

SwapParameters implements the expression.Equality interface.

func (*JoinComparator) ToComparer added in v0.12.0

func (j *JoinComparator) ToComparer() (expression.Comparer, error)

ToComparer implements the expression.Equality interface.

func (*JoinComparator) Type added in v0.12.0

func (j *JoinComparator) Type() sql.Type

Type implements the sql.Expression interface.

func (*JoinComparator) WithChildren added in v0.12.0

func (j *JoinComparator) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

type Literal added in v0.5.0

type Literal struct {
	// contains filtered or unexported fields
}

Literal represents a raw literal (number, string, etc.).

func NewIntegerLiteral added in v0.5.0

func NewIntegerLiteral(integerValue string) (*Literal, error)

NewIntegerLiteral returns a new *Literal containing an integer (INT2/4/8 or NUMERIC) value.

func NewIntervalLiteral added in v0.11.0

func NewIntervalLiteral(duration duration.Duration) *Literal

NewIntervalLiteral returns a new *Literal containing a INTERVAL value.

func NewJSONLiteral added in v0.8.0

func NewJSONLiteral(jsonValue string) *Literal

NewJSONLiteral returns a new *Literal containing a JSON value. This is different from JSONB.

func NewNullLiteral added in v0.7.5

func NewNullLiteral() *Literal

NewNullLiteral returns a new *Literal containing a null value.

func NewNumericLiteral added in v0.6.0

func NewNumericLiteral(numericValue string) (*Literal, error)

NewNumericLiteral returns a new *Literal containing a NUMERIC value.

func NewRawLiteralBool added in v0.7.5

func NewRawLiteralBool(val bool) *Literal

NewRawLiteralBool returns a new *Literal containing a boolean value.

func NewRawLiteralDate added in v0.13.0

func NewRawLiteralDate(date time.Time) *Literal

NewRawLiteralDate returns a new *Literal containing a DATE value.

func NewRawLiteralFloat64 added in v0.7.5

func NewRawLiteralFloat64(val float64) *Literal

NewRawLiteralFloat64 returns a new *Literal containing a float64 value.

func NewRawLiteralInt64 added in v0.7.5

func NewRawLiteralInt64(val int64) *Literal

NewRawLiteralInt64 returns a new *Literal containing an int64 value.

func NewRawLiteralJSON added in v0.13.0

func NewRawLiteralJSON(val string) *Literal

NewRawLiteralJSON returns a new *Literal containing a JSON value.

func NewRawLiteralNumeric added in v0.7.5

func NewRawLiteralNumeric(val decimal.Decimal) *Literal

NewRawLiteralNumeric returns a new *Literal containing a decimal.Decimal value.

func NewRawLiteralOid added in v0.13.0

func NewRawLiteralOid(val uint32) *Literal

NewRawLiteralOid returns a new *Literal containing a OID value.

func NewRawLiteralTime added in v0.13.0

func NewRawLiteralTime(t time.Time) *Literal

NewRawLiteralTime returns a new *Literal containing a TIME value.

func NewRawLiteralTimeTZ added in v0.13.0

func NewRawLiteralTimeTZ(ttz time.Time) *Literal

NewRawLiteralTimeTZ returns a new *Literal containing a TIMETZ value.

func NewRawLiteralTimestamp added in v0.7.5

func NewRawLiteralTimestamp(val time.Time) *Literal

NewRawLiteralTimestamp returns a new *Literal containing a TIMESTAMP value. This is the variant without a time zone.

func NewRawLiteralTimestampTZ added in v0.13.0

func NewRawLiteralTimestampTZ(val time.Time) *Literal

NewRawLiteralTimestampTZ returns a new *Literal containing a TIMESTAMPTZ value. This is the variant with a time zone.

func NewRawLiteralUuid added in v0.13.0

func NewRawLiteralUuid(val uuid.UUID) *Literal

NewRawLiteralUuid returns a new *Literal containing a UUID value.

func NewTextLiteral added in v0.11.1

func NewTextLiteral(stringValue string) *Literal

NewTextLiteral returns a new *Literal containing a TEXT type value. This should be used for internal uses when the type of the value is certain.

func NewUnknownLiteral added in v0.11.1

func NewUnknownLiteral(stringValue string) *Literal

NewUnknownLiteral returns a new *Literal containing a UNKNOWN type value.

func NewUnsafeLiteral added in v0.11.0

func NewUnsafeLiteral(val any, t pgtypes.DoltgresType) *Literal

NewUnsafeLiteral returns a new *Literal containing the given value and type. This should almost never be used, as it does not perform any checking and circumvents type safety, which may lead to hard-to-debug errors. This is currently only used within the analyzer, and will likely be removed in the future.

func (*Literal) Children added in v0.5.0

func (l *Literal) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*Literal) ConformsToLiteralInterface added in v0.5.0

func (l *Literal) ConformsToLiteralInterface()

ConformsToLiteralInterface implements the framework.LiteralInterface interface.

func (*Literal) Eval added in v0.5.0

func (l *Literal) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*Literal) GetDoltgresType added in v0.5.0

func (l *Literal) GetDoltgresType() pgtypes.DoltgresType

GetDoltgresType implements the framework.LiteralInterface interface.

func (*Literal) IsNullable added in v0.5.0

func (l *Literal) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*Literal) Resolved added in v0.5.0

func (l *Literal) Resolved() bool

Resolved implements the sql.Expression interface.

func (*Literal) String added in v0.5.0

func (l *Literal) String() string

String implements the sql.Expression interface.

func (*Literal) ToVitessLiteral added in v0.5.0

func (l *Literal) ToVitessLiteral() *vitess.SQLVal

ToVitessLiteral returns the literal as a Vitess literal. This is strictly for situations where GMS is hardcoded to expect a Vitess literal. This should only be used as a temporary measure, as the GMS code needs to be updated, or the equivalent functionality should be built into Doltgres (recommend the second approach).

func (*Literal) Type added in v0.5.0

func (l *Literal) Type() sql.Type

Type implements the sql.Expression interface.

func (*Literal) Value added in v0.5.0

func (l *Literal) Value() any

Value returns the literal value.

func (*Literal) WithChildren added in v0.5.0

func (l *Literal) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*Literal) WithResolvedChildren added in v0.5.0

func (l *Literal) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type Not added in v0.10.0

type Not struct {
	// contains filtered or unexported fields
}

Not represents a NOT expression.

func NewNot added in v0.10.0

func NewNot() *Not

NewNot returns a new *Not.

func (*Not) Children added in v0.10.0

func (n *Not) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*Not) Eval added in v0.10.0

func (n *Not) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*Not) IsNullable added in v0.10.0

func (n *Not) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*Not) Resolved added in v0.10.0

func (n *Not) Resolved() bool

Resolved implements the sql.Expression interface.

func (*Not) String added in v0.10.0

func (n *Not) String() string

String implements the sql.Expression interface.

func (*Not) Type added in v0.10.0

func (n *Not) Type() sql.Type

Type implements the sql.Expression interface.

func (*Not) WithChildren added in v0.10.0

func (n *Not) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*Not) WithResolvedChildren added in v0.10.0

func (n *Not) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

type UnaryOperator added in v0.5.0

type UnaryOperator struct {
	// contains filtered or unexported fields
}

UnaryOperator represents a VALUE OPERATOR VALUE expression.

func NewUnaryOperator added in v0.5.0

func NewUnaryOperator(operator framework.Operator) *UnaryOperator

NewUnaryOperator returns a new *UnaryOperator.

func (*UnaryOperator) Children added in v0.5.0

func (b *UnaryOperator) Children() []sql.Expression

Children implements the sql.Expression interface.

func (*UnaryOperator) Eval added in v0.5.0

func (b *UnaryOperator) Eval(ctx *sql.Context, row sql.Row) (any, error)

Eval implements the sql.Expression interface.

func (*UnaryOperator) IsNullable added in v0.5.0

func (b *UnaryOperator) IsNullable() bool

IsNullable implements the sql.Expression interface.

func (*UnaryOperator) Resolved added in v0.5.0

func (b *UnaryOperator) Resolved() bool

Resolved implements the sql.Expression interface.

func (*UnaryOperator) String added in v0.5.0

func (b *UnaryOperator) String() string

String implements the sql.Expression interface.

func (*UnaryOperator) Type added in v0.5.0

func (b *UnaryOperator) Type() sql.Type

Type implements the sql.Expression interface.

func (*UnaryOperator) WithChildren added in v0.5.0

func (b *UnaryOperator) WithChildren(children ...sql.Expression) (sql.Expression, error)

WithChildren implements the sql.Expression interface.

func (*UnaryOperator) WithResolvedChildren added in v0.5.0

func (b *UnaryOperator) WithResolvedChildren(children []any) (any, error)

WithResolvedChildren implements the vitess.InjectableExpression interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL