Documentation ¶
Index ¶
- Variables
- func JSONScan(dbValue interface{}, value interface{}) error
- func JSONValue(value interface{}) (driver.Value, error)
- type Bool
- type Datetime
- func (Datetime) DataType(e string) string
- func (dt Datetime) Format(layout string) string
- func (dt Datetime) In(loc *time.Location) Datetime
- func (dt Datetime) IsZero() bool
- func (dt Datetime) MarshalText() ([]byte, error)
- func (dt *Datetime) Scan(value interface{}) error
- func (dt Datetime) String() string
- func (dt Datetime) Unix() int64
- func (dt *Datetime) UnmarshalText(data []byte) (err error)
- func (dt Datetime) Value() (driver.Value, error)
- type MySQLDatetime
- type MySQLTimestamp
- type Timestamp
- func (dt *Timestamp) DataType(engine string) string
- func (dt Timestamp) Format(layout string) string
- func (dt Timestamp) In(loc *time.Location) Timestamp
- func (dt Timestamp) IsZero() bool
- func (dt Timestamp) MarshalText() ([]byte, error)
- func (dt *Timestamp) Scan(value interface{}) error
- func (dt Timestamp) String() string
- func (dt Timestamp) Unix() int64
- func (dt *Timestamp) UnmarshalText(data []byte) (err error)
- func (dt Timestamp) Value() (driver.Value, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( UTC = time.UTC CST = time.FixedZone("CST", 8*60*60) TimestampZero = Timestamp(time.Time{}) TimestampUnixZero = Timestamp(time.Unix(0, 0)) )
View Source
var (
DatetimeZero = Datetime(time.Time{})
)
Functions ¶
Types ¶
type Bool ¶
type Bool int
openapi:type boolean
func (Bool) MarshalJSON ¶
func (Bool) MarshalText ¶
func (*Bool) UnmarshalJSON ¶
func (*Bool) UnmarshalText ¶
type Datetime ¶ added in v2.11.0
openapi:strfmt date-time
func ParseDatetimeFromString ¶ added in v2.11.0
func ParseDatetimeFromStringWithFormatterInCST ¶ added in v2.11.0
func (Datetime) MarshalText ¶ added in v2.11.0
func (*Datetime) UnmarshalText ¶ added in v2.11.0
type MySQLDatetime ¶
type MySQLDatetime = Datetime
type MySQLTimestamp ¶
type MySQLTimestamp = Timestamp
type Timestamp ¶ added in v2.11.0
openapi:strfmt date-time
func ParseTimestampFromString ¶ added in v2.11.0
func ParseTimestampFromStringWithLayout ¶ added in v2.11.0
func (Timestamp) MarshalText ¶ added in v2.11.0
func (*Timestamp) UnmarshalText ¶ added in v2.11.0
Click to show internal directories.
Click to hide internal directories.