20 lines
287 B
Go
Raw Permalink Normal View History

2022-09-20 23:50:01 +08:00
package utils
import "time"
func UnixtimeNano() int64 {
return time.Now().UnixNano()
}
func UnixtimeMicro() int64 {
return time.Now().UnixNano() / 1000
}
func UnixtimeMilli() int64 {
return time.Now().UnixNano() / 1000000
}
func UnixtimeSec() int64 {
return time.Now().Unix()
}