Documentation ¶
Index ¶
- Constants
- func EpochStamp2MicroTime(timestamp int64) time.Time
- func EpochStamp2MilliTime(timestamp int64) time.Time
- func EpochStamp2PGMilliTimeString(tsEpoch int64) string
- func Time2MilliStamp(t time.Time) int64
- func Time2MircoStamp(t time.Time) int64
- func Time2SecondStamp(t time.Time) int64
- func TimeString2MicroTime(s string) (time.Time, error)
- func TimeString2MilliTime(s string) (time.Time, error)
Constants ¶
View Source
const ( // This is really the PG-dumped timestamp format PGTimeFormatMilli = "2006-01-02 15:04:05.999" PGTimeFormatMicro = "2006-01-02 15:04:05.999999" )
Variables ¶
This section is empty.
Functions ¶
func EpochStamp2MicroTime ¶
EpochStamp2MicroTime converts a UNIX epoch time in microsecond (int64) to a local timestamp
func EpochStamp2MilliTime ¶
EpochStamp2MilliTime converts a UNIX epoch time in millisecond (int64) to a local timestamp
func Time2MilliStamp ¶
Time2MilliStamp converts a local timestamp to a UNIX epoch time in millisecond (int64)
func Time2MircoStamp ¶
Time2MircoStamp converts a local timestamp to a UNIX epoch time in mircosecond (int64)
func Time2SecondStamp ¶
Time2SecondStamp converts a local timestamp to a UNIX epoch time in second (int64)
func TimeString2MicroTime ¶
TimeString2MicroTime converts a postgres raw (microsecond) time string into a local time
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.