Documentation
¶
Index ¶
- func CheckPasswordHash(password, hash string) bool
- func EncryptPassword(password string) (string, error)
- func FormatTimeStr(nowTime int64) string
- func GetGenTime(sid int64) string
- func GetGenTimestamp(sid int64) int64
- func GetInt64Val(ctx context.Context, key string) (val int64)
- func GetNodeID(sid int64) int64
- func GetString(ctx context.Context, key string) (val string)
- func GetTimestamp(sid int64) int64
- func GetTimestampStatus() float64
- func GetUid(ctx context.Context) (uid int64)
- func GetUserName(ctx context.Context) (username string)
- func QueryInt64Val(ctx context.Context, key string) (val int64)
- func QueryString(ctx context.Context, key string) (val string)
- type Snowflake
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetInt64Val ¶
GetInt64Val 从上下文获取val
func GetTimestampStatus ¶
func GetTimestampStatus() float64
GetTimestampStatus 获取时间戳已使用的占比:范围(0.0 - 1.0)
func GetUserName ¶
GetUserName 从上下文获取username
func QueryInt64Val ¶
QueryInt64Val 从上下文获取val
Types ¶
Click to show internal directories.
Click to hide internal directories.