Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Gtime ¶
Gtime 是对time.Time类型的扩展,在序列化与反序列化时支持 yyyy-MM-dd HH:mm:ss 时间格式 golang 中 time.Time类型序列化 rfc3339 标准时间格式进行序列化的,此方式序列化出的时间字符串不方便阅读 因此Gtime重写了 MarshalJSON,UnmarshalJSON,MarshalText,UnmarshalText,String 方法来支持 yyyy-MM-dd HH:mm:ss 的格式
func (Gtime) MarshalText ¶
MarshalText implements the encoding.TextMarshaler interface. The time is formatted in RFC 3339 format, with sub-second precision added if present.
func (*Gtime) UnmarshalJSON ¶
UnmarshalJSON time类型json反序列化
Click to show internal directories.
Click to hide internal directories.