Documentation ¶
Index ¶
- Constants
- Variables
- func AnyValueReturnType(typs []types.Type) types.Type
- func ApproxCountReturnType(_ []types.Type) types.Type
- func AvgReturnType(typs []types.Type) types.Type
- func BitAndReturnType(typs []types.Type) types.Type
- func BitOrReturnType(_ []types.Type) types.Type
- func BitXorReturnType(_ []types.Type) types.Type
- func CountReturnType(_ []types.Type) types.Type
- func MaxReturnType(typs []types.Type) types.Type
- func MinReturnType(typs []types.Type) types.Type
- func ReturnType(op int, typ types.Type) (types.Type, error)
- func StdDevPopReturnType(typs []types.Type) types.Type
- func String(b []byte) (s string)
- func SumReturnType(typs []types.Type) types.Type
- func VarianceReturnType(typs []types.Type) types.Type
- type Agg
- func New(op int, dist bool, typ types.Type) (Agg[any], error)
- func NewUnaryAgg[T1, T2 any](op int, priv AggStruct, isCount bool, ityp, otyp types.Type, grows func(int), ...) Agg[*UnaryAgg[T1, T2]]
- func NewUnaryDistAgg[T1, T2 any](op int, priv AggStruct, isCount bool, ityp, otyp types.Type, grows func(int), ...) Agg[*UnaryDistAgg[T1, T2]]
- type AggStruct
- type Aggregate
- type Anyvalue
- func (a *Anyvalue[T]) Eval(vs []T) []T
- func (a *Anyvalue[T]) Fill(i int64, value T, ov T, z int64, isEmpty bool, isNull bool) (T, bool)
- func (a *Anyvalue[T]) Grows(size int)
- func (a *Anyvalue[T]) MarshalBinary() ([]byte, error)
- func (a *Anyvalue[T]) Merge(xIndex int64, yIndex int64, x T, y T, xEmpty bool, yEmpty bool, yAnyValue any) (T, bool)
- func (a *Anyvalue[T]) UnmarshalBinary(data []byte) error
- type ApproxCountDistic
- func (a *ApproxCountDistic[T]) Eval(vs []uint64) []uint64
- func (a *ApproxCountDistic[T]) Fill(n int64, v1 T, v2 uint64, _ int64, isEmpty bool, isNull bool) (uint64, bool)
- func (a *ApproxCountDistic[T]) Grows(n int)
- func (a *ApproxCountDistic[T]) MarshalBinary() ([]byte, error)
- func (a *ApproxCountDistic[T]) Merge(xIndex int64, yIndex int64, x uint64, _ uint64, xEmpty bool, yEmpty bool, ...) (uint64, bool)
- func (a *ApproxCountDistic[T]) UnmarshalBinary(data []byte) error
- type Avg
- func (a *Avg[T]) Eval(vs []float64) []float64
- func (a *Avg[T]) Fill(i int64, value T, ov float64, z int64, isEmpty bool, isNull bool) (float64, bool)
- func (a *Avg[T]) Grows(cnt int)
- func (a *Avg[T]) MarshalBinary() ([]byte, error)
- func (a *Avg[T]) Merge(xIndex int64, yIndex int64, x float64, y float64, xEmpty bool, yEmpty bool, ...) (float64, bool)
- func (a *Avg[T]) UnmarshalBinary(data []byte) error
- type BitAnd
- func (ba *BitAnd[T1]) Eval(vs []uint64) []uint64
- func (ba *BitAnd[T1]) Fill(groupIndex int64, v1 T1, v2 uint64, z int64, isEmpty bool, hasNull bool) (uint64, bool)
- func (ba *BitAnd[T1]) Grows(_ int)
- func (ba *BitAnd[T1]) MarshalBinary() ([]byte, error)
- func (ba *BitAnd[T1]) Merge(groupIndex1, groupIndex2 int64, x, y uint64, isEmpty1 bool, isEmpty2 bool, ...) (uint64, bool)
- func (ba *BitAnd[T1]) UnmarshalBinary(data []byte) error
- type BitOr
- func (bo *BitOr[T1]) Eval(vs []uint64) []uint64
- func (bo *BitOr[T1]) Fill(_ int64, v1 T1, v2 uint64, _ int64, IsEmpty bool, hasNull bool) (uint64, bool)
- func (bo *BitOr[T1]) Grows(_ int)
- func (bo *BitOr[T1]) MarshalBinary() ([]byte, error)
- func (bo *BitOr[T1]) Merge(_, _ int64, x, y uint64, IsEmpty1 bool, IsEmpty2 bool, _ any) (uint64, bool)
- func (bo *BitOr[T1]) UnmarshalBinary(data []byte) error
- type BitXor
- func (bx *BitXor[T1]) Eval(vs []uint64) []uint64
- func (bx *BitXor[T1]) Fill(_ int64, v1 T1, v2 uint64, z int64, IsEmpty bool, hasNull bool) (uint64, bool)
- func (bx *BitXor[T1]) Grows(_ int)
- func (bx *BitXor[T1]) MarshalBinary() ([]byte, error)
- func (bx *BitXor[T1]) Merge(_, _ int64, x, y uint64, IsEmpty1 bool, IsEmpty2 bool, _ any) (uint64, bool)
- func (bx *BitXor[T1]) UnmarshalBinary(data []byte) error
- type BoolMax
- func (m *BoolMax) Eval(vs []bool) []bool
- func (m *BoolMax) Fill(_ int64, value bool, ov bool, _ int64, isEmpty bool, isNull bool) (bool, bool)
- func (m *BoolMax) Grows(_ int)
- func (m *BoolMax) MarshalBinary() ([]byte, error)
- func (m *BoolMax) Merge(_ int64, _ int64, x bool, y bool, xEmpty bool, yEmpty bool, _ any) (bool, bool)
- func (m *BoolMax) UnmarshalBinary(data []byte) error
- type BoolMin
- func (m *BoolMin) Eval(vs []bool) []bool
- func (m *BoolMin) Fill(_ int64, value bool, ov bool, _ int64, isEmpty bool, isNull bool) (bool, bool)
- func (m *BoolMin) Grows(_ int)
- func (m *BoolMin) MarshalBinary() ([]byte, error)
- func (m *BoolMin) Merge(_ int64, _ int64, x bool, y bool, xEmpty bool, yEmpty bool, _ any) (bool, bool)
- func (m *BoolMin) UnmarshalBinary(data []byte) error
- type Compare
- type Count
- func (c *Count[T1]) Eval(vs []int64) []int64
- func (c *Count[T1]) Fill(_ int64, _ T1, v int64, z int64, _ bool, hasNull bool) (int64, bool)
- func (c *Count[T1]) Grows(_ int)
- func (c *Count[T1]) MarshalBinary() ([]byte, error)
- func (c *Count[T1]) Merge(_, _ int64, x, y int64, _ bool, _ bool, _ any) (int64, bool)
- func (c *Count[T1]) UnmarshalBinary(data []byte) error
- type Decimal128AndString
- type Decimal128Avg
- func (a *Decimal128Avg) BatchFill(rs, vs any, start, count int64, vps []uint64, zs []int64, nsp *nulls.Nulls) error
- func (a *Decimal128Avg) Eval(vs []types.Decimal128) []types.Decimal128
- func (a *Decimal128Avg) Fill(i int64, value types.Decimal128, ov types.Decimal128, z int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (a *Decimal128Avg) Grows(cnt int)
- func (a *Decimal128Avg) MarshalBinary() ([]byte, error)
- func (a *Decimal128Avg) Merge(xIndex int64, yIndex int64, x types.Decimal128, y types.Decimal128, ...) (types.Decimal128, bool)
- func (a *Decimal128Avg) UnmarshalBinary(data []byte) error
- type Decimal128Max
- func (m *Decimal128Max) Eval(vs []types.Decimal128) []types.Decimal128
- func (m *Decimal128Max) Fill(_ int64, value types.Decimal128, ov types.Decimal128, _ int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (m *Decimal128Max) Grows(_ int)
- func (m *Decimal128Max) MarshalBinary() ([]byte, error)
- func (m *Decimal128Max) Merge(_ int64, _ int64, x types.Decimal128, y types.Decimal128, xEmpty bool, ...) (types.Decimal128, bool)
- func (m *Decimal128Max) UnmarshalBinary(data []byte) error
- type Decimal128Min
- func (m *Decimal128Min) Eval(vs []types.Decimal128) []types.Decimal128
- func (m *Decimal128Min) Fill(_ int64, value types.Decimal128, ov types.Decimal128, _ int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (m *Decimal128Min) Grows(_ int)
- func (m *Decimal128Min) MarshalBinary() ([]byte, error)
- func (m *Decimal128Min) Merge(_ int64, _ int64, x types.Decimal128, y types.Decimal128, xEmpty bool, ...) (types.Decimal128, bool)
- func (m *Decimal128Min) UnmarshalBinary(data []byte) error
- type Decimal128Sum
- func (s *Decimal128Sum) BatchFill(rs, vs any, start, count int64, vps []uint64, zs []int64, nsp *nulls.Nulls) error
- func (s *Decimal128Sum) Eval(vs []types.Decimal128) []types.Decimal128
- func (s *Decimal128Sum) Fill(_ int64, value types.Decimal128, ov types.Decimal128, z int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (s *Decimal128Sum) Grows(_ int)
- func (s *Decimal128Sum) MarshalBinary() ([]byte, error)
- func (s *Decimal128Sum) Merge(_ int64, _ int64, x types.Decimal128, y types.Decimal128, xEmpty bool, ...) (types.Decimal128, bool)
- func (s *Decimal128Sum) UnmarshalBinary(data []byte) error
- type Decimal64Avg
- func (a *Decimal64Avg) BatchFill(rs, vs any, start, count int64, vps []uint64, zs []int64, nsp *nulls.Nulls) error
- func (a *Decimal64Avg) Eval(vs []types.Decimal128) []types.Decimal128
- func (a *Decimal64Avg) Fill(i int64, value types.Decimal64, ov types.Decimal128, z int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (a *Decimal64Avg) Grows(cnt int)
- func (a *Decimal64Avg) MarshalBinary() ([]byte, error)
- func (a *Decimal64Avg) Merge(xIndex int64, yIndex int64, x types.Decimal128, y types.Decimal128, ...) (types.Decimal128, bool)
- func (a *Decimal64Avg) UnmarshalBinary(data []byte) error
- type Decimal64Max
- func (m *Decimal64Max) Eval(vs []types.Decimal64) []types.Decimal64
- func (m *Decimal64Max) Fill(_ int64, value types.Decimal64, ov types.Decimal64, _ int64, isEmpty bool, ...) (types.Decimal64, bool)
- func (m *Decimal64Max) Grows(_ int)
- func (m *Decimal64Max) MarshalBinary() ([]byte, error)
- func (m *Decimal64Max) Merge(_ int64, _ int64, x types.Decimal64, y types.Decimal64, xEmpty bool, ...) (types.Decimal64, bool)
- func (m *Decimal64Max) UnmarshalBinary(data []byte) error
- type Decimal64Min
- func (m *Decimal64Min) Eval(vs []types.Decimal64) []types.Decimal64
- func (m *Decimal64Min) Fill(_ int64, value types.Decimal64, ov types.Decimal64, _ int64, isEmpty bool, ...) (types.Decimal64, bool)
- func (m *Decimal64Min) Grows(_ int)
- func (m *Decimal64Min) MarshalBinary() ([]byte, error)
- func (m *Decimal64Min) Merge(_ int64, _ int64, x types.Decimal64, y types.Decimal64, xEmpty bool, ...) (types.Decimal64, bool)
- func (m *Decimal64Min) UnmarshalBinary(data []byte) error
- type Decimal64Sum
- func (s *Decimal64Sum) BatchFill(rs, vs any, start, count int64, vps []uint64, zs []int64, nsp *nulls.Nulls) error
- func (s *Decimal64Sum) Eval(vs []types.Decimal64) []types.Decimal64
- func (s *Decimal64Sum) Fill(_ int64, value types.Decimal64, ov types.Decimal64, z int64, isEmpty bool, ...) (types.Decimal64, bool)
- func (s *Decimal64Sum) Grows(_ int)
- func (s *Decimal64Sum) MarshalBinary() ([]byte, error)
- func (s *Decimal64Sum) Merge(_ int64, _ int64, x types.Decimal64, y types.Decimal64, xEmpty bool, ...) (types.Decimal64, bool)
- func (s *Decimal64Sum) UnmarshalBinary(data []byte) error
- type EncodeAgg
- type EncodeAggDistinct
- type EncodeDecimalV
- type EncodeVariance
- type Max
- func (m *Max[T]) Eval(vs []T) []T
- func (m *Max[T]) Fill(_ int64, value T, ov T, _ int64, isEmpty bool, isNull bool) (T, bool)
- func (m *Max[T]) Grows(_ int)
- func (m *Max[T]) MarshalBinary() ([]byte, error)
- func (m *Max[T]) Merge(_ int64, _ int64, x T, y T, xEmpty bool, yEmpty bool, _ any) (T, bool)
- func (m *Max[T]) UnmarshalBinary(data []byte) error
- type Min
- func (m *Min[T]) Eval(vs []T) []T
- func (m *Min[T]) Fill(_ int64, value T, ov T, _ int64, isEmpty bool, isNull bool) (T, bool)
- func (m *Min[T]) Grows(_ int)
- func (m *Min[T]) MarshalBinary() ([]byte, error)
- func (m *Min[T]) Merge(_ int64, _ int64, x T, y T, xEmpty bool, yEmpty bool, _ any) (T, bool)
- func (m *Min[T]) UnmarshalBinary(data []byte) error
- type Numeric
- type ReturnTyp
- type StdD128
- func (s *StdD128) Eval(vs []types.Decimal128) []types.Decimal128
- func (s *StdD128) Fill(groupIndex int64, v1 types.Decimal128, v2 types.Decimal128, z int64, ...) (types.Decimal128, bool)
- func (s *StdD128) Grows(size int)
- func (s *StdD128) MarshalBinary() ([]byte, error)
- func (s *StdD128) Merge(groupIndex1, groupIndex2 int64, x, y types.Decimal128, IsEmpty1 bool, ...) (types.Decimal128, bool)
- func (s *StdD128) UnmarshalBinary(data []byte) error
- type StdD64
- func (s *StdD64) Eval(vs []types.Decimal128) []types.Decimal128
- func (s *StdD64) Fill(groupIndex int64, v1 types.Decimal64, v2 types.Decimal128, z int64, ...) (types.Decimal128, bool)
- func (s *StdD64) Grows(size int)
- func (s *StdD64) MarshalBinary() ([]byte, error)
- func (s *StdD64) Merge(groupIndex1, groupIndex2 int64, x, y types.Decimal128, IsEmpty1 bool, ...) (types.Decimal128, bool)
- func (s *StdD64) UnmarshalBinary(data []byte) error
- type Stddevpop
- func (sdp *Stddevpop[T1]) Eval(vs []float64) []float64
- func (sdp *Stddevpop[T1]) Fill(groupIndex int64, v1 T1, v2 float64, z int64, IsEmpty bool, hasNull bool) (float64, bool)
- func (sdp *Stddevpop[T1]) Grows(sizes int)
- func (sdp *Stddevpop[T1]) MarshalBinary() ([]byte, error)
- func (sdp *Stddevpop[T1]) Merge(groupIndex1, groupIndex2 int64, x, y float64, IsEmpty1 bool, IsEmpty2 bool, ...) (float64, bool)
- func (sdp *Stddevpop[T1]) UnmarshalBinary(data []byte) error
- type StrMax
- func (m *StrMax) Eval(vs [][]byte) [][]byte
- func (m *StrMax) Fill(_ int64, value []byte, ov []byte, _ int64, isEmpty bool, isNull bool) ([]byte, bool)
- func (m *StrMax) Grows(_ int)
- func (m *StrMax) MarshalBinary() ([]byte, error)
- func (m *StrMax) Merge(_ int64, _ int64, x []byte, y []byte, xEmpty bool, yEmpty bool, _ any) ([]byte, bool)
- func (m *StrMax) UnmarshalBinary(data []byte) error
- type StrMin
- func (m *StrMin) Eval(vs [][]byte) [][]byte
- func (m *StrMin) Fill(_ int64, value []byte, ov []byte, _ int64, isEmpty bool, isNull bool) ([]byte, bool)
- func (m *StrMin) Grows(_ int)
- func (m *StrMin) MarshalBinary() ([]byte, error)
- func (m *StrMin) Merge(_ int64, _ int64, x []byte, y []byte, xEmpty bool, yEmpty bool, _ any) ([]byte, bool)
- func (m *StrMin) UnmarshalBinary(data []byte) error
- type Sum
- func (s *Sum[T1, T2]) Eval(vs []T2) []T2
- func (s *Sum[T1, T2]) Fill(_ int64, value T1, ov T2, z int64, isEmpty bool, isNull bool) (T2, bool)
- func (s *Sum[T1, T2]) Grows(_ int)
- func (s *Sum[T1, T2]) MarshalBinary() ([]byte, error)
- func (s *Sum[T1, T2]) Merge(_ int64, _ int64, x T2, y T2, xEmpty bool, yEmpty bool, _ any) (T2, bool)
- func (s *Sum[T1, T2]) UnmarshalBinary(data []byte) error
- type UnaryAgg
- func (a *UnaryAgg[T1, T2]) BatchFill(start int64, os []uint8, vps []uint64, zs []int64, vecs []*vector.Vector) error
- func (a *UnaryAgg[T1, T2]) BatchMerge(b Agg[any], start int64, os []uint8, vps []uint64) error
- func (a *UnaryAgg[T1, T2]) BulkFill(i int64, zs []int64, vecs []*vector.Vector) error
- func (a *UnaryAgg[T1, T2]) Dup() Agg[any]
- func (a *UnaryAgg[T1, T2]) Eval(m *mpool.MPool) (*vector.Vector, error)
- func (a *UnaryAgg[T1, T2]) Fill(i int64, sel, z int64, vecs []*vector.Vector) error
- func (a *UnaryAgg[T1, T2]) Free(m *mpool.MPool)
- func (a *UnaryAgg[T1, T2]) GetInputTypes() []types.Type
- func (a *UnaryAgg[T1, T2]) GetOperatorId() int
- func (a *UnaryAgg[T1, T2]) Grows(size int, m *mpool.MPool) error
- func (a *UnaryAgg[T1, T2]) InputTypes() []types.Type
- func (a *UnaryAgg[T1, T2]) IsDistinct() bool
- func (a *UnaryAgg[T1, T2]) MarshalBinary() ([]byte, error)
- func (a *UnaryAgg[T1, T2]) Merge(b Agg[any], x, y int64) error
- func (a *UnaryAgg[T1, T2]) OutputType() types.Type
- func (a *UnaryAgg[T1, T2]) String() string
- func (a *UnaryAgg[T1, T2]) UnmarshalBinary(data []byte, mp *mpool.MPool) error
- func (a *UnaryAgg[T1, T2]) WildAggReAlloc(m *mpool.MPool) error
- type UnaryDistAgg
- func (a *UnaryDistAgg[T1, T2]) BatchFill(start int64, os []uint8, vps []uint64, zs []int64, vecs []*vector.Vector) error
- func (a *UnaryDistAgg[T1, T2]) BatchMerge(b Agg[any], start int64, os []uint8, vps []uint64) error
- func (a *UnaryDistAgg[T1, T2]) BulkFill(i int64, zs []int64, vecs []*vector.Vector) error
- func (a *UnaryDistAgg[T1, T2]) Dup() Agg[any]
- func (a *UnaryDistAgg[T1, T2]) Eval(m *mpool.MPool) (*vector.Vector, error)
- func (a *UnaryDistAgg[T1, T2]) Fill(i int64, sel, z int64, vecs []*vector.Vector) error
- func (a *UnaryDistAgg[T1, T2]) Free(m *mpool.MPool)
- func (a *UnaryDistAgg[T1, T2]) GetInputTypes() []types.Type
- func (a *UnaryDistAgg[T1, T2]) GetOperatorId() int
- func (a *UnaryDistAgg[T1, T2]) Grows(size int, m *mpool.MPool) error
- func (a *UnaryDistAgg[T1, T2]) InputTypes() []types.Type
- func (a *UnaryDistAgg[T1, T2]) IsDistinct() bool
- func (a *UnaryDistAgg[T1, T2]) MarshalBinary() ([]byte, error)
- func (a *UnaryDistAgg[T1, T2]) Merge(b Agg[any], x, y int64) error
- func (a *UnaryDistAgg[T1, T2]) OutputType() types.Type
- func (a *UnaryDistAgg[T1, T2]) String() string
- func (a *UnaryDistAgg[T1, T2]) UnmarshalBinary(data []byte, m *mpool.MPool) error
- func (a *UnaryDistAgg[T1, T2]) WildAggReAlloc(m *mpool.MPool) error
- type UuidMax
- func (m *UuidMax) Eval(vs []types.Uuid) []types.Uuid
- func (m *UuidMax) Fill(_ int64, value types.Uuid, ov types.Uuid, _ int64, isEmpty bool, isNull bool) (types.Uuid, bool)
- func (m *UuidMax) Grows(_ int)
- func (m *UuidMax) MarshalBinary() ([]byte, error)
- func (m *UuidMax) Merge(_ int64, _ int64, x types.Uuid, y types.Uuid, xEmpty bool, yEmpty bool, _ any) (types.Uuid, bool)
- func (m *UuidMax) UnmarshalBinary(data []byte) error
- type UuidMin
- func (m *UuidMin) Eval(vs []types.Uuid) []types.Uuid
- func (m *UuidMin) Fill(_ int64, value types.Uuid, ov types.Uuid, _ int64, isEmpty bool, isNull bool) (types.Uuid, bool)
- func (m *UuidMin) Grows(_ int)
- func (m *UuidMin) MarshalBinary() ([]byte, error)
- func (m *UuidMin) Merge(_ int64, _ int64, x types.Uuid, y types.Uuid, xEmpty bool, yEmpty bool, _ any) (types.Uuid, bool)
- func (m *UuidMin) UnmarshalBinary(data []byte) error
- type VD128
- func (v *VD128) Eval(vs []types.Decimal128) []types.Decimal128
- func (v *VD128) Fill(i int64, v1 types.Decimal128, v2 types.Decimal128, z int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (v *VD128) Grows(cnt int)
- func (v *VD128) MarshalBinary() ([]byte, error)
- func (v *VD128) Merge(xIndex, yIndex int64, x types.Decimal128, y types.Decimal128, xEmpty bool, ...) (types.Decimal128, bool)
- func (v *VD128) UnmarshalBinary(data []byte) error
- type VD64
- func (v *VD64) Eval(vs []types.Decimal128) []types.Decimal128
- func (v *VD64) Fill(i int64, v1 types.Decimal64, v2 types.Decimal128, z int64, isEmpty bool, ...) (types.Decimal128, bool)
- func (v *VD64) Grows(cnt int)
- func (v *VD64) MarshalBinary() ([]byte, error)
- func (v *VD64) Merge(xIndex, yIndex int64, x types.Decimal128, y types.Decimal128, xEmpty bool, ...) (types.Decimal128, bool)
- func (v *VD64) UnmarshalBinary(data []byte) error
- type Variance
- func (variance *Variance[T1]) Eval(vs []float64) []float64
- func (variance *Variance[T1]) Fill(groupIndex int64, v1 T1, v2 float64, z int64, IsEmpty bool, hasNull bool) (float64, bool)
- func (variance *Variance[T1]) Grows(count int)
- func (variance *Variance[T1]) MarshalBinary() ([]byte, error)
- func (variance *Variance[T1]) Merge(groupIndex1, groupIndex2 int64, x, y float64, IsEmpty1 bool, IsEmpty2 bool, ...) (float64, bool)
- func (variance *Variance[T1]) UnmarshalBinary(data []byte) error
Constants ¶
View Source
const ( AggregateSum = iota AggregateAvg AggregateMax AggregateMin AggregateCount AggregateStarCount AggregateApproxCountDistinct AggregateVariance AggregateBitAnd AggregateBitXor AggregateBitOr AggregateStdDevPop AggregateAnyValue )
Variables ¶
View Source
var Names = [...]string{ AggregateSum: "sum", AggregateAvg: "avg", AggregateMax: "max", AggregateMin: "min", AggregateCount: "count", AggregateStarCount: "starcount", AggregateApproxCountDistinct: "approx_count_distinct", AggregateVariance: "var", AggregateBitAnd: "bit_and", AggregateBitXor: "bit_xor", AggregateBitOr: "bit_or", AggregateStdDevPop: "stddev_pop", AggregateAnyValue: "any", }
Functions ¶
func ReturnType ¶ added in v0.6.0
ReturnType get aggregate operator's return type according to its operator-id and input-types.
Types ¶
type Agg ¶
type Agg[T any] interface { encoding.BinaryMarshaler //encoding.BinaryUnmarshaler UnmarshalBinary(data []byte, m *mpool.MPool) error // Dup will duplicate a new agg with the same type. Dup() Agg[any] // Type return the type of the agg's result. OutputType() types.Type // InputType return the type of the agg's input. InputTypes() []types.Type // String return related information of the agg. // used to show query plans. String() string // Free the agg. Free(*mpool.MPool) // Grows allocates n groups for the agg. Grows(n int, m *mpool.MPool) error // Eval method calculates and returns the final result of the aggregate function. Eval(_ *mpool.MPool) (*vector.Vector, error) // Fill use the rowIndex-rows of vector to update the data of groupIndex-group. // rowCount indicates the number of times the rowIndex-row is repeated. Fill(groupIndex int64, rowIndex int64, rowCount int64, vecs []*vector.Vector) error // BulkFill use a whole vector to update the data of agg's group // groupIndex is the index number of the group // rowCounts is the count number of each row. BulkFill(groupIndex int64, rowCounts []int64, vecs []*vector.Vector) error // BatchFill use part of the vector to update the data of agg's group // os(origin-s) records information about which groups need to be updated // if length of os is N, we use first N of vps to do update work. // And if os[i] > 0, it means the agg's (vps[i]-1)th group is a new one (never been assigned a value), // Maybe this feature can help us to do some optimization work. // So we use the os as a parameter but not len(os). // // agg's (vps[i]-1)th group is related to vector's (offset+i)th row. // rowCounts[i] is count number of the row[i] // For a more detailed introduction of rowCounts, please refer to comments of Function Fill. BatchFill(offset int64, os []uint8, vps []uint64, rowCounts []int64, vecs []*vector.Vector) error // Merge will merge a couple of group between 2 aggregate function structures. // It merges the groupIndex1-group of agg1 and // groupIndex2-group of agg2 Merge(agg2 Agg[any], groupIndex1 int64, groupIndex2 int64) error // BatchMerge merges multi groups of agg1 and agg2 // agg1's (vps[i]-1)th group is related to agg2's (start+i)th group // For more introduction of os, please refer to comments of Function BatchFill. BatchMerge(agg2 Agg[any], start int64, os []uint8, vps []uint64) error // GetInputTypes get types of aggregate's input arguments. GetInputTypes() []types.Type // GetOperatorId get types of aggregate's aggregate id. GetOperatorId() int IsDistinct() bool // WildAggReAlloc reallocate for agg structure from memory pool. WildAggReAlloc(m *mpool.MPool) error }
Agg agg interface
func NewUnaryAgg ¶
func NewUnaryAgg[T1, T2 any](op int, priv AggStruct, isCount bool, ityp, otyp types.Type, grows func(int), eval func([]T2) []T2, merge func(int64, int64, T2, T2, bool, bool, any) (T2, bool), fill func(int64, T1, T2, int64, bool, bool) (T2, bool), batchFill func(any, any, int64, int64, []uint64, []int64, *nulls.Nulls) error) Agg[*UnaryAgg[T1, T2]]
func NewUnaryDistAgg ¶
type AggStruct ¶ added in v0.6.0
type AggStruct interface { encoding.BinaryMarshaler encoding.BinaryUnmarshaler }
type Anyvalue ¶ added in v0.6.0
func NewAnyValue ¶ added in v0.6.0
func (*Anyvalue[T]) MarshalBinary ¶ added in v0.6.0
func (*Anyvalue[T]) UnmarshalBinary ¶ added in v0.6.0
type ApproxCountDistic ¶ added in v0.6.0
func NewApproxc ¶ added in v0.6.0
func NewApproxc[T any]() *ApproxCountDistic[T]
func (*ApproxCountDistic[T]) Eval ¶ added in v0.6.0
func (a *ApproxCountDistic[T]) Eval(vs []uint64) []uint64
func (*ApproxCountDistic[T]) Grows ¶ added in v0.6.0
func (a *ApproxCountDistic[T]) Grows(n int)
func (*ApproxCountDistic[T]) MarshalBinary ¶ added in v0.6.0
func (a *ApproxCountDistic[T]) MarshalBinary() ([]byte, error)
func (*ApproxCountDistic[T]) UnmarshalBinary ¶ added in v0.6.0
func (a *ApproxCountDistic[T]) UnmarshalBinary(data []byte) error
type Avg ¶ added in v0.6.0
func (*Avg[T]) MarshalBinary ¶ added in v0.6.0
func (*Avg[T]) UnmarshalBinary ¶ added in v0.6.0
type BitAnd ¶ added in v0.6.0
func (*BitAnd[T1]) MarshalBinary ¶ added in v0.6.0
func (*BitAnd[T1]) UnmarshalBinary ¶ added in v0.6.0
type BitOr ¶ added in v0.6.0
func (*BitOr[T1]) MarshalBinary ¶ added in v0.6.0
func (*BitOr[T1]) UnmarshalBinary ¶ added in v0.6.0
type BitXor ¶ added in v0.6.0
func (*BitXor[T1]) MarshalBinary ¶ added in v0.6.0
func (*BitXor[T1]) UnmarshalBinary ¶ added in v0.6.0
type BoolMax ¶ added in v0.6.0
type BoolMax struct { }
func NewBoolMax ¶ added in v0.6.0
func NewBoolMax() *BoolMax
func (*BoolMax) MarshalBinary ¶ added in v0.6.0
func (*BoolMax) UnmarshalBinary ¶ added in v0.6.0
type BoolMin ¶ added in v0.6.0
type BoolMin struct { }
func NewBoolMin ¶ added in v0.6.0
func NewBoolMin() *BoolMin
func (*BoolMin) MarshalBinary ¶ added in v0.6.0
func (*BoolMin) UnmarshalBinary ¶ added in v0.6.0
type Compare ¶ added in v0.6.0
type Compare interface { constraints.Integer | constraints.Float | types.Date | types.Datetime | types.Timestamp }
type Count ¶ added in v0.6.0
type Count[T1 types.OrderedT | Decimal128AndString] struct { // IsStar is true: count(*) IsStar bool }
func NewCount ¶ added in v0.6.0
func NewCount[T1 types.OrderedT | Decimal128AndString](isStar bool) *Count[T1]
func (*Count[T1]) MarshalBinary ¶ added in v0.6.0
func (*Count[T1]) UnmarshalBinary ¶ added in v0.6.0
type Decimal128AndString ¶ added in v0.6.0
type Decimal128Avg ¶ added in v0.6.0
type Decimal128Avg struct {
Cnts []int64
}
func NewD128Avg ¶ added in v0.6.0
func NewD128Avg() *Decimal128Avg
func (*Decimal128Avg) Eval ¶ added in v0.6.0
func (a *Decimal128Avg) Eval(vs []types.Decimal128) []types.Decimal128
func (*Decimal128Avg) Fill ¶ added in v0.6.0
func (a *Decimal128Avg) Fill(i int64, value types.Decimal128, ov types.Decimal128, z int64, isEmpty bool, isNull bool) (types.Decimal128, bool)
func (*Decimal128Avg) Grows ¶ added in v0.6.0
func (a *Decimal128Avg) Grows(cnt int)
func (*Decimal128Avg) MarshalBinary ¶ added in v0.6.0
func (a *Decimal128Avg) MarshalBinary() ([]byte, error)
func (*Decimal128Avg) Merge ¶ added in v0.6.0
func (a *Decimal128Avg) Merge(xIndex int64, yIndex int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, yAvg any) (types.Decimal128, bool)
func (*Decimal128Avg) UnmarshalBinary ¶ added in v0.6.0
func (a *Decimal128Avg) UnmarshalBinary(data []byte) error
type Decimal128Max ¶ added in v0.6.0
type Decimal128Max struct { }
func NewD128Max ¶ added in v0.6.0
func NewD128Max() *Decimal128Max
func (*Decimal128Max) Eval ¶ added in v0.6.0
func (m *Decimal128Max) Eval(vs []types.Decimal128) []types.Decimal128
func (*Decimal128Max) Fill ¶ added in v0.6.0
func (m *Decimal128Max) Fill(_ int64, value types.Decimal128, ov types.Decimal128, _ int64, isEmpty bool, isNull bool) (types.Decimal128, bool)
func (*Decimal128Max) Grows ¶ added in v0.6.0
func (m *Decimal128Max) Grows(_ int)
func (*Decimal128Max) MarshalBinary ¶ added in v0.6.0
func (m *Decimal128Max) MarshalBinary() ([]byte, error)
func (*Decimal128Max) Merge ¶ added in v0.6.0
func (m *Decimal128Max) Merge(_ int64, _ int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, _ any) (types.Decimal128, bool)
func (*Decimal128Max) UnmarshalBinary ¶ added in v0.6.0
func (m *Decimal128Max) UnmarshalBinary(data []byte) error
type Decimal128Min ¶ added in v0.6.0
type Decimal128Min struct { }
func NewD128Min ¶ added in v0.6.0
func NewD128Min() *Decimal128Min
func (*Decimal128Min) Eval ¶ added in v0.6.0
func (m *Decimal128Min) Eval(vs []types.Decimal128) []types.Decimal128
func (*Decimal128Min) Fill ¶ added in v0.6.0
func (m *Decimal128Min) Fill(_ int64, value types.Decimal128, ov types.Decimal128, _ int64, isEmpty bool, isNull bool) (types.Decimal128, bool)
func (*Decimal128Min) Grows ¶ added in v0.6.0
func (m *Decimal128Min) Grows(_ int)
func (*Decimal128Min) MarshalBinary ¶ added in v0.6.0
func (m *Decimal128Min) MarshalBinary() ([]byte, error)
func (*Decimal128Min) Merge ¶ added in v0.6.0
func (m *Decimal128Min) Merge(_ int64, _ int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, _ any) (types.Decimal128, bool)
func (*Decimal128Min) UnmarshalBinary ¶ added in v0.6.0
func (m *Decimal128Min) UnmarshalBinary(data []byte) error
type Decimal128Sum ¶ added in v0.6.0
type Decimal128Sum struct { }
func NewD128Sum ¶ added in v0.6.0
func NewD128Sum() *Decimal128Sum
func (*Decimal128Sum) Eval ¶ added in v0.6.0
func (s *Decimal128Sum) Eval(vs []types.Decimal128) []types.Decimal128
func (*Decimal128Sum) Fill ¶ added in v0.6.0
func (s *Decimal128Sum) Fill(_ int64, value types.Decimal128, ov types.Decimal128, z int64, isEmpty bool, isNull bool) (types.Decimal128, bool)
func (*Decimal128Sum) Grows ¶ added in v0.6.0
func (s *Decimal128Sum) Grows(_ int)
func (*Decimal128Sum) MarshalBinary ¶ added in v0.6.0
func (s *Decimal128Sum) MarshalBinary() ([]byte, error)
func (*Decimal128Sum) Merge ¶ added in v0.6.0
func (s *Decimal128Sum) Merge(_ int64, _ int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, _ any) (types.Decimal128, bool)
func (*Decimal128Sum) UnmarshalBinary ¶ added in v0.6.0
func (s *Decimal128Sum) UnmarshalBinary(data []byte) error
type Decimal64Avg ¶ added in v0.6.0
type Decimal64Avg struct {
Cnts []int64
}
func NewD64Avg ¶ added in v0.6.0
func NewD64Avg() *Decimal64Avg
func (*Decimal64Avg) Eval ¶ added in v0.6.0
func (a *Decimal64Avg) Eval(vs []types.Decimal128) []types.Decimal128
func (*Decimal64Avg) Fill ¶ added in v0.6.0
func (a *Decimal64Avg) Fill(i int64, value types.Decimal64, ov types.Decimal128, z int64, isEmpty bool, isNull bool) (types.Decimal128, bool)
func (*Decimal64Avg) Grows ¶ added in v0.6.0
func (a *Decimal64Avg) Grows(cnt int)
func (*Decimal64Avg) MarshalBinary ¶ added in v0.6.0
func (a *Decimal64Avg) MarshalBinary() ([]byte, error)
func (*Decimal64Avg) Merge ¶ added in v0.6.0
func (a *Decimal64Avg) Merge(xIndex int64, yIndex int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, yAvg any) (types.Decimal128, bool)
func (*Decimal64Avg) UnmarshalBinary ¶ added in v0.6.0
func (a *Decimal64Avg) UnmarshalBinary(data []byte) error
type Decimal64Max ¶ added in v0.6.0
type Decimal64Max struct { }
func NewD64Max ¶ added in v0.6.0
func NewD64Max() *Decimal64Max
func (*Decimal64Max) Eval ¶ added in v0.6.0
func (m *Decimal64Max) Eval(vs []types.Decimal64) []types.Decimal64
func (*Decimal64Max) Grows ¶ added in v0.6.0
func (m *Decimal64Max) Grows(_ int)
func (*Decimal64Max) MarshalBinary ¶ added in v0.6.0
func (m *Decimal64Max) MarshalBinary() ([]byte, error)
func (*Decimal64Max) UnmarshalBinary ¶ added in v0.6.0
func (m *Decimal64Max) UnmarshalBinary(data []byte) error
type Decimal64Min ¶ added in v0.6.0
type Decimal64Min struct { }
func NewD64Min ¶ added in v0.6.0
func NewD64Min() *Decimal64Min
func (*Decimal64Min) Eval ¶ added in v0.6.0
func (m *Decimal64Min) Eval(vs []types.Decimal64) []types.Decimal64
func (*Decimal64Min) Grows ¶ added in v0.6.0
func (m *Decimal64Min) Grows(_ int)
func (*Decimal64Min) MarshalBinary ¶ added in v0.6.0
func (m *Decimal64Min) MarshalBinary() ([]byte, error)
func (*Decimal64Min) UnmarshalBinary ¶ added in v0.6.0
func (m *Decimal64Min) UnmarshalBinary(data []byte) error
type Decimal64Sum ¶ added in v0.6.0
type Decimal64Sum struct { }
func NewD64Sum ¶ added in v0.6.0
func NewD64Sum() *Decimal64Sum
func (*Decimal64Sum) Eval ¶ added in v0.6.0
func (s *Decimal64Sum) Eval(vs []types.Decimal64) []types.Decimal64
func (*Decimal64Sum) Grows ¶ added in v0.6.0
func (s *Decimal64Sum) Grows(_ int)
func (*Decimal64Sum) MarshalBinary ¶ added in v0.6.0
func (s *Decimal64Sum) MarshalBinary() ([]byte, error)
func (*Decimal64Sum) UnmarshalBinary ¶ added in v0.6.0
func (s *Decimal64Sum) UnmarshalBinary(data []byte) error
type EncodeAggDistinct ¶ added in v0.6.0
type EncodeDecimalV ¶ added in v0.6.0
type EncodeDecimalV struct { Sum []types.Decimal128 Counts []int64 }
type EncodeVariance ¶ added in v0.6.0
type Max ¶ added in v0.6.0
type Max[T Compare] struct { }
func (*Max[T]) MarshalBinary ¶ added in v0.6.0
func (*Max[T]) UnmarshalBinary ¶ added in v0.6.0
type Min ¶ added in v0.6.0
type Min[T Compare] struct { }
func (*Min[T]) MarshalBinary ¶ added in v0.6.0
func (*Min[T]) UnmarshalBinary ¶ added in v0.6.0
type ReturnTyp ¶ added in v0.6.0
if input type is int8/int16/int32/int64, the return type is int64 if input type is uint8/uint16/uint32/uint64, the return type is uint64 f input type is float32/float64, the return type is float64
type StdD128 ¶ added in v0.6.0
type StdD128 struct {
Variance *VD128
}
func NewStdD128 ¶ added in v0.6.0
func NewStdD128() *StdD128
func (*StdD128) Eval ¶ added in v0.6.0
func (s *StdD128) Eval(vs []types.Decimal128) []types.Decimal128
func (*StdD128) Fill ¶ added in v0.6.0
func (s *StdD128) Fill(groupIndex int64, v1 types.Decimal128, v2 types.Decimal128, z int64, IsEmpty bool, hasNull bool) (types.Decimal128, bool)
func (*StdD128) MarshalBinary ¶ added in v0.6.0
func (*StdD128) Merge ¶ added in v0.6.0
func (s *StdD128) Merge(groupIndex1, groupIndex2 int64, x, y types.Decimal128, IsEmpty1 bool, IsEmpty2 bool, agg any) (types.Decimal128, bool)
func (*StdD128) UnmarshalBinary ¶ added in v0.6.0
type StdD64 ¶ added in v0.6.0
type StdD64 struct {
Variance *VD64
}
func (*StdD64) Eval ¶ added in v0.6.0
func (s *StdD64) Eval(vs []types.Decimal128) []types.Decimal128
func (*StdD64) MarshalBinary ¶ added in v0.6.0
func (*StdD64) Merge ¶ added in v0.6.0
func (s *StdD64) Merge(groupIndex1, groupIndex2 int64, x, y types.Decimal128, IsEmpty1 bool, IsEmpty2 bool, agg any) (types.Decimal128, bool)
func (*StdD64) UnmarshalBinary ¶ added in v0.6.0
type Stddevpop ¶ added in v0.6.0
func NewStdDevPop ¶ added in v0.6.0
NewStdDevPop is used to create a StdDevPop which supports float,int,uint
func (*Stddevpop[T1]) MarshalBinary ¶ added in v0.6.0
func (*Stddevpop[T1]) UnmarshalBinary ¶ added in v0.6.0
type StrMax ¶ added in v0.6.0
type StrMax struct { }
func (*StrMax) MarshalBinary ¶ added in v0.6.0
func (*StrMax) UnmarshalBinary ¶ added in v0.6.0
type StrMin ¶ added in v0.6.0
type StrMin struct { }
func (*StrMin) MarshalBinary ¶ added in v0.6.0
func (*StrMin) UnmarshalBinary ¶ added in v0.6.0
type Sum ¶ added in v0.6.0
func (*Sum[T1, T2]) MarshalBinary ¶ added in v0.6.0
func (*Sum[T1, T2]) UnmarshalBinary ¶ added in v0.6.0
type UnaryAgg ¶
type UnaryAgg[T1, T2 any] struct { // contains filtered or unexported fields }
UnaryAgg generic aggregation function with one input vector and without distinct
func (*UnaryAgg[T1, T2]) BatchMerge ¶
func (*UnaryAgg[T1, T2]) GetInputTypes ¶ added in v0.6.0
func (*UnaryAgg[T1, T2]) GetOperatorId ¶ added in v0.6.0
func (*UnaryAgg[T1, T2]) InputTypes ¶
func (*UnaryAgg[T1, T2]) IsDistinct ¶ added in v0.6.0
func (*UnaryAgg[T1, T2]) MarshalBinary ¶ added in v0.6.0
func (*UnaryAgg[T1, T2]) OutputType ¶
func (*UnaryAgg[T1, T2]) UnmarshalBinary ¶ added in v0.6.0
type UnaryDistAgg ¶
type UnaryDistAgg[T1, T2 any] struct { // contains filtered or unexported fields }
UnaryDistAgg generic aggregation function with one input vector and with distinct
func (*UnaryDistAgg[T1, T2]) BatchMerge ¶
func (*UnaryDistAgg[T1, T2]) Dup ¶
func (a *UnaryDistAgg[T1, T2]) Dup() Agg[any]
func (*UnaryDistAgg[T1, T2]) Free ¶
func (a *UnaryDistAgg[T1, T2]) Free(m *mpool.MPool)
func (*UnaryDistAgg[T1, T2]) GetInputTypes ¶ added in v0.6.0
func (a *UnaryDistAgg[T1, T2]) GetInputTypes() []types.Type
func (*UnaryDistAgg[T1, T2]) GetOperatorId ¶ added in v0.6.0
func (a *UnaryDistAgg[T1, T2]) GetOperatorId() int
func (*UnaryDistAgg[T1, T2]) Grows ¶
func (a *UnaryDistAgg[T1, T2]) Grows(size int, m *mpool.MPool) error
func (*UnaryDistAgg[T1, T2]) InputTypes ¶
func (a *UnaryDistAgg[T1, T2]) InputTypes() []types.Type
func (*UnaryDistAgg[T1, T2]) IsDistinct ¶ added in v0.6.0
func (a *UnaryDistAgg[T1, T2]) IsDistinct() bool
func (*UnaryDistAgg[T1, T2]) MarshalBinary ¶ added in v0.6.0
func (a *UnaryDistAgg[T1, T2]) MarshalBinary() ([]byte, error)
func (*UnaryDistAgg[T1, T2]) Merge ¶
func (a *UnaryDistAgg[T1, T2]) Merge(b Agg[any], x, y int64) error
Merge a[x] += b[y]
func (*UnaryDistAgg[T1, T2]) OutputType ¶
func (a *UnaryDistAgg[T1, T2]) OutputType() types.Type
func (*UnaryDistAgg[T1, T2]) String ¶
func (a *UnaryDistAgg[T1, T2]) String() string
func (*UnaryDistAgg[T1, T2]) UnmarshalBinary ¶ added in v0.6.0
func (a *UnaryDistAgg[T1, T2]) UnmarshalBinary(data []byte, m *mpool.MPool) error
func (*UnaryDistAgg[T1, T2]) WildAggReAlloc ¶ added in v0.6.0
func (a *UnaryDistAgg[T1, T2]) WildAggReAlloc(m *mpool.MPool) error
type UuidMax ¶ added in v0.6.0
type UuidMax struct { }
func NewUuidMax ¶ added in v0.6.0
func NewUuidMax() *UuidMax
func (*UuidMax) MarshalBinary ¶ added in v0.6.0
func (*UuidMax) UnmarshalBinary ¶ added in v0.6.0
type UuidMin ¶ added in v0.6.0
type UuidMin struct { }
func NewUuidMin ¶ added in v0.6.0
func NewUuidMin() *UuidMin
func (*UuidMin) MarshalBinary ¶ added in v0.6.0
func (*UuidMin) UnmarshalBinary ¶ added in v0.6.0
type VD128 ¶ added in v0.6.0
type VD128 struct { Sum []types.Decimal128 Counts []int64 }
VD128 Variance for decimal128
func (*VD128) Eval ¶ added in v0.6.0
func (v *VD128) Eval(vs []types.Decimal128) []types.Decimal128
func (*VD128) Fill ¶ added in v0.6.0
func (v *VD128) Fill(i int64, v1 types.Decimal128, v2 types.Decimal128, z int64, isEmpty bool, isNull bool) (types.Decimal128, bool)
func (*VD128) MarshalBinary ¶ added in v0.6.0
func (*VD128) Merge ¶ added in v0.6.0
func (v *VD128) Merge(xIndex, yIndex int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, agg any) (types.Decimal128, bool)
func (*VD128) UnmarshalBinary ¶ added in v0.6.0
type VD64 ¶ added in v0.6.0
type VD64 struct { Sum []types.Decimal128 Counts []int64 }
VD64 Variance for decimal64
func (*VD64) Eval ¶ added in v0.6.0
func (v *VD64) Eval(vs []types.Decimal128) []types.Decimal128
func (*VD64) MarshalBinary ¶ added in v0.6.0
func (*VD64) Merge ¶ added in v0.6.0
func (v *VD64) Merge(xIndex, yIndex int64, x types.Decimal128, y types.Decimal128, xEmpty bool, yEmpty bool, agg any) (types.Decimal128, bool)
func (*VD64) UnmarshalBinary ¶ added in v0.6.0
type Variance ¶ added in v0.6.0
func NewVariance ¶ added in v0.6.0
NewVariance is used to create a Variance which supports float,int,uint
func (*Variance[T1]) MarshalBinary ¶ added in v0.6.0
func (*Variance[T1]) UnmarshalBinary ¶ added in v0.6.0
Source Files ¶
Click to show internal directories.
Click to hide internal directories.