Documentation
¶
Index ¶
- func MeasureDistance(left, right interface{}, distanceType DistanceType) (interface{}, error)
- func NewDistance(distanceType DistanceType, left sql.Expression, right sql.Expression) sql.Expression
- func NewL2SquaredDistance(left, right sql.Expression) sql.Expression
- type Distance
- func (d Distance) CollationCoercibility(_ *sql.Context) (collation sql.CollationID, coercibility byte)
- func (d Distance) Description() string
- func (d Distance) Eval(ctx *sql.Context, row sql.Row) (interface{}, error)
- func (d Distance) FunctionName() string
- func (d Distance) String() string
- func (d Distance) Type() sql.Type
- func (d Distance) WithChildren(children ...sql.Expression) (sql.Expression, error)
- type DistanceL2Squared
- type DistanceType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MeasureDistance ¶
func MeasureDistance(left, right interface{}, distanceType DistanceType) (interface{}, error)
func NewDistance ¶
func NewDistance(distanceType DistanceType, left sql.Expression, right sql.Expression) sql.Expression
NewDistance creates a new Distance expression.
func NewL2SquaredDistance ¶
func NewL2SquaredDistance(left, right sql.Expression) sql.Expression
Types ¶
type Distance ¶
type Distance struct { DistanceType DistanceType expression.BinaryExpressionStub }
func (Distance) CollationCoercibility ¶
func (Distance) Description ¶
func (Distance) FunctionName ¶
func (Distance) WithChildren ¶
func (d Distance) WithChildren(children ...sql.Expression) (sql.Expression, error)
type DistanceL2Squared ¶
type DistanceL2Squared struct{}
func (DistanceL2Squared) CanEval ¶
func (d DistanceL2Squared) CanEval(other DistanceType) bool
func (DistanceL2Squared) Description ¶
func (d DistanceL2Squared) Description() string
func (DistanceL2Squared) Eval ¶
func (d DistanceL2Squared) Eval(left []float64, right []float64) (float64, error)
func (DistanceL2Squared) FunctionName ¶
func (d DistanceL2Squared) FunctionName() string
func (DistanceL2Squared) String ¶
func (d DistanceL2Squared) String() string
Click to show internal directories.
Click to hide internal directories.