protocol

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: May 5, 2022 License: Apache-2.0 Imports: 41 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Attr = iota
	Unary
	Binary
	Multi
	Paren
	Func
	Star
	Value
)
View Source
const (
	DefaultRing = iota
	AvgRing
	CountRing
	StarCountRing
	ApproxCountDistinctRing
	// Max
	MaxInt8Ring
	MaxInt32Ring
	MaxDateRing
	MaxInt16Ring
	MaxInt64Ring
	MaxDatetimeRing
	MaxUInt8Ring
	MaxUInt16Ring
	MaxUInt32Ring
	MaxUInt64Ring
	MaxFloat32Ring
	MaxFloat64Ring
	MaxStrRing
	// Min
	MinInt8Ring
	MinInt32Ring
	MinDateRing
	MinInt16Ring
	MinInt64Ring
	MinDatetimeRing
	MinUInt8Ring
	MinUInt16Ring
	MinUInt32Ring
	MinUInt64Ring
	MinFloat32Ring
	MinFloat64Ring
	MinStrRing
	// Sum
	SumIntRing
	SumUIntRing
	SumFloatRing
	// Variance
	VarianceRing
	// BitAnd
	BitAndNumericRing
	//Bitor
	BitOrRing
	// BitXor
	BitXorRing
	// StdDevPop
	StdDevPopRing
)

Variables

This section is empty.

Functions

func DecodeBatch

func DecodeBatch(data []byte) (*batch.Batch, []byte, error)

func DecodeBatchWithProcess

func DecodeBatchWithProcess(data []byte, proc *process.Process) (*batch.Batch, []byte, error)

func DecodeExtend

func DecodeExtend(data []byte) (extend.Extend, []byte, error)

func DecodeInstruction

func DecodeInstruction(data []byte) (vm.Instruction, []byte, error)

func DecodeInstructions

func DecodeInstructions(data []byte) (vm.Instructions, []byte, error)

func DecodeRing

func DecodeRing(data []byte) (ring.Ring, []byte, error)

func DecodeRingWithProcess

func DecodeRingWithProcess(data []byte, proc *process.Process) (ring.Ring, []byte, error)

func DecodeVector

func DecodeVector(data []byte) (*vector.Vector, []byte, error)

func EncodeBatch

func EncodeBatch(bat *batch.Batch, buf *bytes.Buffer) error

func EncodeExtend

func EncodeExtend(e extend.Extend, buf *bytes.Buffer) error

func EncodeInstruction

func EncodeInstruction(in vm.Instruction, buf *bytes.Buffer) error

func EncodeInstructions

func EncodeInstructions(ins vm.Instructions, buf *bytes.Buffer) error

func EncodeRing

func EncodeRing(r ring.Ring, buf *bytes.Buffer) error

func EncodeScope

func EncodeScope(s Scope, buf *bytes.Buffer) error

func EncodeVector

func EncodeVector(v *vector.Vector, buf *bytes.Buffer) error

func UntransferTransformArg

func UntransferTransformArg(arg TransformArgument) *transform.Argument

Types

type DedupArgument

type DedupArgument struct {
}

type Field

type Field struct {
	Attr string
	Type int8
}

type JoinArgument

type JoinArgument struct {
	Result []string
	Vars   [][]string
}

type LimitArgument

type LimitArgument struct {
	Seen  uint64
	Limit uint64
}

type MergeArgument

type MergeArgument struct {
}

type Node

type Node struct {
	Id   string
	Addr string
	Data []byte
}

type OffsetArgument

type OffsetArgument struct {
	Seen   uint64
	Offset uint64
}

type OplusArgument

type OplusArgument struct {
	Typ int
}

type OrderArgument

type OrderArgument struct {
	Fs []Field
}

type OutputArgument

type OutputArgument struct {
	Attrs []string
}

type PlusArgument

type PlusArgument struct {
	Typ int
}

type ProjectionArgument

type ProjectionArgument struct {
	Rs []uint64
	As []string
}

type RestrictArgument

type RestrictArgument struct {
	Attrs []string
}

type Scope

type Scope struct {
	Magic      int
	DataSource Source
	PreScopes  []Scope
	NodeInfo   Node
	Ins        vm.Instructions
}

func DecodeScope

func DecodeScope(data []byte) (Scope, []byte, error)

type Source

type Source struct {
	IsMerge      bool
	SchemaName   string
	RelationName string
	RefCounts    []uint64
	Attributes   []string
}

type TimesArgument

type TimesArgument struct {
	Result []string
	Vars   [][]string
}

type TopArgument

type TopArgument struct {
	Limit int64
	Fs    []Field
}

type TransformArgument

type TransformArgument struct {
	IsNull      bool
	Typ         int
	IsMerge     bool
	FreeVars    []string
	HasRestrict bool
	Restrict    RestrictArgument
	HasProj     bool
	Projection  ProjectionArgument
	BoundVars   []Transformer
}

func TransferTransformArg

func TransferTransformArg(arg *transform.Argument) TransformArgument

type Transformer

type Transformer struct {
	Op    int
	Ref   int
	Name  string
	Alias string
}

type UntransformArgument

type UntransformArgument struct {
	Type     int
	FreeVars []string
}

Jump to

Keyboard shortcuts

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