datatypes

package
v1.6.8 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Array

type Array[T any] []T

func (*Array[T]) Scan added in v1.2.8

func (d *Array[T]) Scan(value interface{}) error

func (Array[T]) Value added in v1.2.8

func (d Array[T]) Value() (driver.Value, error)

type FloatArray

type FloatArray[T constraints.Float] []T

func (*FloatArray[T]) Scan

func (d *FloatArray[T]) Scan(value interface{}) error

func (FloatArray[T]) Value

func (d FloatArray[T]) Value() (driver.Value, error)

type IntArray

type IntArray[T constraints.Integer] []T

adpter postgres

func (*IntArray[T]) Scan

func (d *IntArray[T]) Scan(value interface{}) error

func (IntArray[T]) Value

func (d IntArray[T]) Value() (driver.Value, error)

type Json added in v1.2.11

type Json map[string]any

func (Json) GormDataType added in v1.2.11

func (Json) GormDataType() string

func (*Json) Scan added in v1.2.11

func (j *Json) Scan(value interface{}) error

实现 sql.Scanner 接口,Scan 将 value 扫描至 Json

func (Json) Value added in v1.2.11

func (j Json) Value() (driver.Value, error)

实现 driver.Valuer 接口,Value 返回 json value

type JsonArray added in v1.2.11

type JsonArray []map[string]any

func (*JsonArray) GormDataType added in v1.2.11

func (*JsonArray) GormDataType() string

func (*JsonArray) Scan added in v1.2.11

func (j *JsonArray) Scan(value interface{}) error

实现 sql.Scanner 接口,Scan 将 value 扫描至 Json

func (JsonArray) Value added in v1.2.11

func (j JsonArray) Value() (driver.Value, error)

实现 driver.Valuer 接口,Value 返回 json value

type JsonArrayT added in v1.2.11

type JsonArrayT[T any] []T

func (*JsonArrayT[T]) GormDataType added in v1.2.11

func (*JsonArrayT[T]) GormDataType() string

func (*JsonArrayT[T]) Scan added in v1.2.11

func (j *JsonArrayT[T]) Scan(value interface{}) error

实现 sql.Scanner 接口,Scan 将 value 扫描至 Json

func (JsonArrayT[T]) Value added in v1.2.11

func (j JsonArrayT[T]) Value() (driver.Value, error)

实现 driver.Valuer 接口,Value 返回 json value

type JsonB added in v1.2.11

type JsonB []byte

func (*JsonB) GormDataType added in v1.2.11

func (*JsonB) GormDataType() string

func (*JsonB) Scan added in v1.2.11

func (j *JsonB) Scan(value interface{}) error

实现 sql.Scanner 接口,Scan 将 value 扫描至 JsonB

func (JsonB) Value added in v1.2.11

func (j JsonB) Value() (driver.Value, error)

实现 driver.Valuer 接口,Value 返回 json value

type JsonStr added in v1.2.11

type JsonStr string

func (*JsonStr) GormDataType added in v1.2.11

func (*JsonStr) GormDataType() string

func (*JsonStr) Scan added in v1.2.11

func (j *JsonStr) Scan(value interface{}) error

实现 sql.Scanner 接口,Scan 将 value 扫描至 JsonStr

func (JsonStr) Value added in v1.2.11

func (j JsonStr) Value() (driver.Value, error)

实现 driver.Valuer 接口,Value 返回 json value

type JsonT added in v1.2.11

type JsonT[T any] struct {
	Json *T
}

func (*JsonT[T]) GormDataType added in v1.2.11

func (*JsonT[T]) GormDataType() string

func (*JsonT[T]) Scan added in v1.2.11

func (j *JsonT[T]) Scan(value interface{}) error

实现 sql.Scanner 接口,Scan 将 value 扫描至 Json

func (JsonT[T]) Value added in v1.2.11

func (j JsonT[T]) Value() (driver.Value, error)

实现 driver.Valuer 接口,Value 返回 json value

type StringArray

type StringArray []string

func (*StringArray) Scan

func (d *StringArray) Scan(value interface{}) error

func (StringArray) Value

func (d StringArray) Value() (driver.Value, error)

Jump to

Keyboard shortcuts

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