xtype

package
v0.0.0-...-4705fdb Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Duration

type Duration xtime.Duration

Duration be used toml unmarshal string time, like 1s, 500ms.

func (Duration) Shrink

Shrink will decrease the duration by comparing with context's timeout duration and return new timeout\context\CancelFunc.

func (*Duration) UnmarshalText

func (d *Duration) UnmarshalText(text []byte) error

UnmarshalText unmarshal text to duration.

type Hms

type Hms int64

Hms be used to MySql timestamp converting.

func (Hms) MarshalJSON

func (jt Hms) MarshalJSON() ([]byte, error)

func (*Hms) Scan

func (jt *Hms) Scan(src interface{}) (err error)

Scan scan time.

func (Hms) Time

func (jt Hms) Time() xtime.Time

Hms get time.

func (*Hms) UnMarshalJSON

func (jt *Hms) UnMarshalJSON(b []byte) (err error)

func (Hms) Value

func (jt Hms) Value() (driver.Value, error)

Value get time value.

type Mdhm

type Mdhm int64

Mdhm be used to MySql timestamp converting.

func (Mdhm) MarshalJSON

func (jt Mdhm) MarshalJSON() ([]byte, error)

func (*Mdhm) Scan

func (jt *Mdhm) Scan(src interface{}) (err error)

Scan scan time.

func (Mdhm) Time

func (jt Mdhm) Time() xtime.Time

Mdhm get time.

func (*Mdhm) UnMarshalJSON

func (jt *Mdhm) UnMarshalJSON(b []byte) (err error)

func (Mdhm) Value

func (jt Mdhm) Value() (driver.Value, error)

Value get time value.

type Time

type Time int64

Time be used to MySql timestamp converting.

func (Time) MarshalJSON

func (jt Time) MarshalJSON() ([]byte, error)

func (*Time) Scan

func (jt *Time) Scan(src interface{}) (err error)

Scan scan time.

func (Time) Time

func (jt Time) Time() xtime.Time

Time get time.

func (*Time) UnMarshalJSON

func (jt *Time) UnMarshalJSON(b []byte) (err error)

func (Time) Value

func (jt Time) Value() (driver.Value, error)

Value get time value.

type XFloat

type XFloat float64

Time be used to MySql timestamp converting.

func (XFloat) MarshalJSON

func (jt XFloat) MarshalJSON() ([]byte, error)

func (*XFloat) Scan

func (jt *XFloat) Scan(src interface{}) (err error)

Scan scan time.

func (XFloat) String

func (jt XFloat) String() string

func (*XFloat) UnMarshalJSON

func (jt *XFloat) UnMarshalJSON(b []byte) (err error)

func (XFloat) Value

func (jt XFloat) Value() (driver.Value, error)

Value get time value.

type YTime

type YTime int64

YTime be used to MySql timestamp converting.

func (YTime) MarshalJSON

func (jt YTime) MarshalJSON() ([]byte, error)

func (*YTime) Scan

func (jt *YTime) Scan(src interface{}) (err error)

Scan scan time.

func (YTime) String

func (jt YTime) String() string

func (YTime) Time

func (jt YTime) Time() xtime.Time

YTime get time.

func (*YTime) UnMarshalJSON

func (jt *YTime) UnMarshalJSON(b []byte) (err error)

func (YTime) Value

func (jt YTime) Value() (driver.Value, error)

Value get time value.

type Ymdhi

type Ymdhi int64

Ymdhi be used to MySql timestamp converting.

func (Ymdhi) MarshalJSON

func (jt Ymdhi) MarshalJSON() ([]byte, error)

func (*Ymdhi) Scan

func (jt *Ymdhi) Scan(src interface{}) (err error)

Scan scan time.

func (Ymdhi) String

func (jt Ymdhi) String() string

func (Ymdhi) Time

func (jt Ymdhi) Time() xtime.Time

Ymdhi get time.

func (*Ymdhi) UnMarshalJSON

func (jt *Ymdhi) UnMarshalJSON(b []byte) (err error)

func (Ymdhi) Value

func (jt Ymdhi) Value() (driver.Value, error)

Value get time value.

type ZTime

type ZTime int64

ZTime be used to MySql timestamp converting.

func (ZTime) MarshalJSON

func (jt ZTime) MarshalJSON() ([]byte, error)

func (*ZTime) Scan

func (jt *ZTime) Scan(src interface{}) (err error)

Scan scan time.

func (ZTime) String

func (jt ZTime) String() string

func (ZTime) Time

func (jt ZTime) Time() xtime.Time

ZTime get time.

func (*ZTime) UnMarshalJSON

func (jt *ZTime) UnMarshalJSON(b []byte) (err error)

func (ZTime) Value

func (jt ZTime) Value() (driver.Value, error)

Value get time value.

Jump to

Keyboard shortcuts

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