projection

package
v0.0.0-...-60a9d3e Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewProjection

func NewProjection(node queries.Node, expressions []ProjectionExpression) (queries.Node, error)

Types

type ProjectionExpression

type ProjectionExpression interface {
	Dealias(name string, fields []shared.Field, alias string) ProjectionExpression
	Expand(fields []shared.Field) ([]aliasProjection, error)
}

func NewAliasProjectionExpression

func NewAliasProjectionExpression(expression expressions.Expression, alias string) ProjectionExpression

func NewTableWildcardProjectionExpression

func NewTableWildcardProjectionExpression(relationName string) ProjectionExpression

func NewWildcardProjectionExpression

func NewWildcardProjectionExpression() ProjectionExpression

type Projector

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

func NewProjector

func NewProjector(name string, fields []shared.Field, expressions []ProjectionExpression) (*Projector, error)

func (*Projector) Fields

func (p *Projector) Fields() []shared.Field

func (*Projector) Optimize

func (p *Projector) Optimize()

func (*Projector) ProjectRow

func (p *Projector) ProjectRow(ctx queries.Context, row shared.Row) (shared.Row, error)

func (*Projector) String

func (p *Projector) String() string

Jump to

Keyboard shortcuts

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