Documentation ¶
Index ¶
- Variables
- func CurrentDate() (date string)
- func Datetime() (datetime string)
- func Elapsed(what string) func()
- func IsInteger(str string) (ok bool)
- func MMHash(buf []byte) uint64
- func Md5File(path string) (string, int64, error)
- func Md5Reader(reader io.Reader) (string, int64, error)
- func Md5hex(data []byte) string
- func MustPwdEncode(rawPassword string) (encodePassword string)
- func Now() (now int64)
- func PwdCompare(hashedPassword, rawPassword string) error
- func PwdEncode(rawPassword string) (string, error)
- func RandomCode(length int) string
- func RandomInviteCode(length int) string
- func RandomString(n int) string
- func Sha1File(path string) (string, int64, error)
- func Sha1Reader(reader io.Reader) (string, int64, error)
- func Sha1hex(data []byte) string
- func Uint32ToBase64(value uint32) (base64val string)
- func Uint64ToStrID(id int64, m1, m2, m3 string) string
- func Uint64ToUID(id int64) (uid string)
- func UnixTimestamp(datetime string) (unixtime int64)
- type CheckSum
Constants ¶
This section is empty.
Variables ¶
View Source
var ( GitBranch = "not set" GitCommit = "not set" BuildTime = C.GoString(C.goBaselibBuildTime()) )
View Source
var ErrDataInvalid error
Functions ¶
func MustPwdEncode ¶
MustPwdEncode 使用bcrypt算法加密密码, 出错会抛出ERR_SERVER_ERROR异常.
func Uint32ToBase64 ¶
Uint32ToBase64 uint32转成base64格式.
func Uint64ToStrID ¶
func Uint64ToUID ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.