Documentation
¶
Index ¶
- func Base64Decode(s string) (string, error)
- func Base64DecodeWithoutErr(s string) string
- func Base64Encode(s string) string
- func Base64URLDecode(s string) (string, error)
- func Base64URLEncode(s string) string
- func BoolPtr(b bool) *bool
- func CallerInfo(skip int) string
- func ClientIP(ctx *gin.Context) string
- func ConStringToInt64(s string) (int64, error)
- func ConStringToInt64WithoutErr(s string) int64
- func ConvertOpId(opId string) string
- func Day() stringdeprecated
- func Debug(keyChains ...string) bool
- func ErrCode(err error) int
- func FormatToWan(num int64) string
- func GetEnv() string
- func GrpcCtx(ctx context.Context) context.Context
- func HostId() string
- func Hour() stringdeprecated
- func Int64Ptr(i int64) *int64
- func IsDevEnv() bool
- func IsInterfaceNil(v interface{}) bool
- func IsLetter(s string) bool
- func IsProEnv() bool
- func IsTestEnv() bool
- func LastMonth() stringdeprecated
- func LastWeek() stringdeprecated
- func MD5(s string) string
- func Marshal(v interface{}) (string, error)
- func MarshalWithoutErr(v interface{}) string
- func MergeByJson(from interface{}, to interface{})
- func MergeByReflection(from interface{}, to interface{}) errordeprecated
- func MergeConfig(config1 *viper.Viper, config2 *viper.Viper) *viper.Viper
- func MidnightTody() time.Timedeprecated
- func Milliseconds() int64
- func Minute() stringdeprecated
- func Month() stringdeprecated
- func NewCtxBK() context.Context
- func OpId(ctx context.Context) string
- func OpIdWithoutDefault(ctx context.Context) string
- func RandInt64InRange(min, max int64) int64
- func RenewCtx(ctx context.Context) context.Context
- func Second() stringdeprecated
- func UUIDWithoutHyphen() string
- func Uid(ctx context.Context) string
- func Unmarshal(data string, v interface{}) error
- func UrlContainsCMS(ctx context.Context) bool
- func Week() stringdeprecated
- func WeekDay() time.Weekdaydeprecated
- func Year() stringdeprecated
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Base64Decode ¶ added in v1.1.29
Base64Decode 解码 base64 字符串
func Base64DecodeWithoutErr ¶ added in v1.1.29
Base64DecodeWithoutErr 解码 base64 字符串,忽略错误
func Base64URLDecode ¶ added in v1.1.29
Base64URLDecode URL 安全的 base64 解码
func Base64URLEncode ¶ added in v1.1.29
Base64URLEncode URL 安全的 base64 编码
func CallerInfo ¶ added in v1.1.43
func ConStringToInt64 ¶
func ConStringToInt64WithoutErr ¶ added in v0.4.4
func ConvertOpId ¶ added in v1.1.46
func FormatToWan ¶ added in v0.9.9
func IsInterfaceNil ¶ added in v1.1.26
func IsInterfaceNil(v interface{}) bool
func MarshalWithoutErr ¶
func MarshalWithoutErr(v interface{}) string
func MergeByJson ¶
func MergeByJson(from interface{}, to interface{})
func MergeByReflection
deprecated
func MergeByReflection(from interface{}, to interface{}) error
Deprecated: 已废弃
func MidnightTody
deprecated
added in
v0.2.9
func Milliseconds ¶
func Milliseconds() int64
func OpIdWithoutDefault ¶
func RandInt64InRange ¶ added in v0.4.3
RandInt64InRange 生成 [min, max) 的 int64 随机数
func UUIDWithoutHyphen ¶
func UUIDWithoutHyphen() string
func UrlContainsCMS ¶ added in v0.8.5
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.