Documentation
¶
Index ¶
- func AesDeCrypt(content []byte) ([]byte, error)
- func AesEnCrypt(plainBytes []byte) []byte
- func FileHash(filePath string, h hash.Hash) (string, error)
- func FilterSymbol(src string) string
- func GeneratePrivateIp(input string) string
- func InArrayInt64(src int64, target []int64) bool
- func InArrayString(src string, target []string) bool
- func InArrayUint64(src uint64, target []uint64) bool
- func IsEmpty(val any) bool
- func IsPrivateIp(ipString string) bool
- func Md5EnCrypt(data string) string
- func PKCS7Padding(data []byte, blockSize int) []byte
- func Random(l int, t int) string
- func RandomImei(prefix string) string
- func RandomMeid(prefix string) string
- func TernaryIf[T any](condition bool, trueValue, falseValue T) T
- func TernaryIfFunc[T any](condition bool, trueValue, falseValue func() T) T
- type LocalTime
- func (t LocalTime) IsZero() bool
- func (t LocalTime) MarshalJSON() ([]byte, error)
- func (t LocalTime) MarshalText() ([]byte, error)
- func (t *LocalTime) Scan(value interface{}) error
- func (t LocalTime) String() string
- func (t LocalTime) Time() time.Time
- func (t *LocalTime) UnmarshalJSON(data []byte) error
- func (t *LocalTime) UnmarshalText(data []byte) error
- func (t LocalTime) Value() (driver.Value, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GeneratePrivateIp ¶
GeneratePrivateIp @Description: 通过字符串生成固定内网IP
func InArrayInt64 ¶
InArrayInt64 @Description: 判断int64是否在数组内
func InArrayString ¶
InArrayString @Description: 判断字符串是否在数组内
func InArrayUint64 ¶
InArrayUint64 @Description: 判断uint64是否在数组内
func PKCS7Padding ¶
PKCS7Padding @Description: 添加PKCS7填充
func TernaryIfFunc ¶
TernaryIfFunc @Description: 三元表达式-返回方法
Types ¶
type LocalTime ¶
LocalTime 自定义时间类型
func (LocalTime) MarshalJSON ¶
MarshalJSON 实现 json.Marshaler 接口
func (LocalTime) MarshalText ¶
MarshalText 文本序列化接口支持(用于 csv、form、query)
func (*LocalTime) UnmarshalJSON ¶
UnmarshalJSON 实现 json.Unmarshaler 接口
func (*LocalTime) UnmarshalText ¶
UnmarshalText 文本序列化接口支持(用于 csv、form、query)
Click to show internal directories.
Click to hide internal directories.