xtype

package module
v0.0.0-...-c285e0e Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2024 License: MIT Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Numbers

type Numbers []int

Numbers is int array for connecting mysql types and json

func (Numbers) Contains

func (t Numbers) Contains(s int) bool

func (Numbers) MarshalJSON

func (t Numbers) MarshalJSON() ([]byte, error)

func (Numbers) Remove

func (t Numbers) Remove(s int) Numbers

Remove item which value is s

func (Numbers) SAdd

func (t Numbers) SAdd(s int) Numbers

SAdd add as set

func (*Numbers) Scan

func (t *Numbers) Scan(src interface{}) error

Scan implements the Scanner interface.

func (Numbers) String

func (t Numbers) String() string

func (*Numbers) UnmarshalJSON

func (t *Numbers) UnmarshalJSON(data []byte) error

func (Numbers) Value

func (t Numbers) Value() (driver.Value, error)

Value implements the driver Valuer interface.

type Strings

type Strings []string

Strings is string array for connecting mysql types and json

func (Strings) Contains

func (t Strings) Contains(s string) bool

func (Strings) Intersectant

func (t Strings) Intersectant(s Strings) bool

func (Strings) MarshalJSON

func (t Strings) MarshalJSON() ([]byte, error)

MarshalJSON interface

func (Strings) Remove

func (t Strings) Remove(s string) Strings

Remove item which value is s

func (Strings) SAdd

func (t Strings) SAdd(s string) Strings

SAdd add as set

func (*Strings) Scan

func (t *Strings) Scan(src interface{}) error

Scan implements the Scanner interface.

func (Strings) String

func (t Strings) String() string

func (Strings) Sub

func (t Strings) Sub(s Strings) Strings

func (Strings) Union

func (t Strings) Union(s Strings) Strings

func (*Strings) UnmarshalJSON

func (t *Strings) UnmarshalJSON(data []byte) error

UnmarshalJSON interface

func (Strings) Value

func (t Strings) Value() (driver.Value, error)

Value implements the driver Valuer interface.

type Values

type Values map[string]string

Values maps a string key to a list of values. It is typically used for object key.

func ParseQuery

func ParseQuery(src string) (Values, error)

Parse parses the encoded values string

func (Values) Del

func (v Values) Del(key string)

Del deletes the values associated with key.

func (Values) Encode

func (v Values) Encode() string

Encode encodes the values into URL encoded form ("bar-baz_foo-quux") sorted by key.

func (Values) Get

func (v Values) Get(key string) string

Get gets the value of the given key. If there are no values associated with the key, Get returns the empty string.

func (Values) Set

func (v Values) Set(key, value string)

Set sets the key to value. It replaces any existing values. don't contain _ and - in values, use [a-z0-9] only

Jump to

Keyboard shortcuts

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