Documentation ¶
Index ¶
- type DurationUnit
- type Time
- func (c *Time) Duration(dur time.Duration) (format string)
- func (c *Time) DurationToUnit(dur time.Duration) (format DurationUnit)
- func (c *Time) TimeStringDateOnly(dur time.Time) (format string)
- func (c *Time) TimeStringTimeOnly(dur time.Time) (format string)
- func (c *Time) TimeStringTimeOnlyWithMilliSecond(s time.Time) (ts string)
- func (c *Time) TimeStringWitLongDate(dur time.Time) (format string)
- func (c *Time) TimeStringWithDate(dur time.Time) (format string)
- func (c *Time) UnixTime(t int64) (ts time.Time)
- func (c *Time) UnixTimeNano(t int64) (ts time.Time)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DurationUnit ¶
type DurationUnit struct { Day int `json:"day"` Hour int `json:"hour"` Minute int `json:"minute"` Second int `json:"second"` }
DurationUnit -
type Time ¶
type Time struct{}
func (*Time) DurationToUnit ¶
func (c *Time) DurationToUnit(dur time.Duration) (format DurationUnit)
DurationToUnit - convert time duration to individual unit
func (*Time) TimeStringDateOnly ¶
TimeStringDateOnly -
func (*Time) TimeStringTimeOnly ¶
TimeStringTimeOnly -
func (*Time) TimeStringTimeOnlyWithMilliSecond ¶
TimeStringTimeOnlyWithMilliSecond -
func (*Time) TimeStringWitLongDate ¶
TimeStringWitLongDate -
func (*Time) TimeStringWithDate ¶
TimeStringWithDate -
Click to show internal directories.
Click to hide internal directories.