Documentation ¶
Index ¶
- Variables
- func AsBool(v Value) (bool, error)
- func AsBytes(v Value) ([]byte, error)
- func AsFloat(v Value) (float64, error)
- func AsInt(v Value) (*big.Int, error)
- func AsInt64(v Value) (int64, error)
- func AsInterval(v Value) (time.Duration, error)
- func AsTimestamp(v Value) (time.Time, error)
- func Cmp(a, b Value) (_ int, isNull bool, retErr error)
- func IsInt64(v Value) bool
- func MakeBinaryOpError(op string, left, right Value, cause error) error
- func MakeUnaryOpError(op string, val Value, cause error) error
- func Sign(v Value) int
- type BinaryOpError
- type CompareError
- type ConvertError
- type Kind
- type UnaryOpError
- type Value
- func Add(a, b Value) (_ Value, retErr error)
- func AsArray(v Value) ([]Value, error)
- func Div(a, b Value) (_ Value, retErr error)
- func FloatDiv(a, b Value) (_ Value, retErr error)
- func MakeArray(a []Value) Value
- func MakeBool(b bool) Value
- func MakeBytes(b []byte) Value
- func MakeFloat(f float64) Value
- func MakeInt(i *big.Int) Value
- func MakeInt64(i int64) Value
- func MakeInterval(d time.Duration) Value
- func MakeNumberFromLiteral(s string) (Value, error)
- func MakeTimestamp(t time.Time) Value
- func Mod(a, b Value) (_ Value, retErr error)
- func Mul(a, b Value) (_ Value, retErr error)
- func Neg(a Value) (_ Value, retErr error)
- func Sub(a, b Value) (_ Value, retErr error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrDivideByZero = errors.New("divide by zero")
Functions ¶
Types ¶
type BinaryOpError ¶
func (*BinaryOpError) Error ¶
func (e *BinaryOpError) Error() string
func (*BinaryOpError) Unwrap ¶
func (e *BinaryOpError) Unwrap() error
type CompareError ¶
type CompareError struct {
Left, Right Value
}
func (*CompareError) Error ¶
func (e *CompareError) Error() string
type ConvertError ¶
func (*ConvertError) Error ¶
func (e *ConvertError) Error() string
type UnaryOpError ¶
func (*UnaryOpError) Error ¶
func (e *UnaryOpError) Error() string
type Value ¶
var Null Value = nullVal{}
func MakeInterval ¶
func MakeNumberFromLiteral ¶
MakeNumberFromLiteral makes a numeric value from a string literal. The string literal may be a decimal integer, a hexadecimal integer, or a floating-point number.
func MakeTimestamp ¶
Click to show internal directories.
Click to hide internal directories.