Documentation
¶
Index ¶
- func Decrypt(ciphertext string, key []byte) (string, error)
- func Encrypt(plaintext string, key []byte) (string, error)
- func EncryptToByte(plaintext string, key []byte) ([]byte, error)
- func GenerateRandomKey(timestamp int64) []byte
- func GetIDButNotNumber(baseName string) string
- func IsEmailValid(email string) bool
- func IsPhoneNumberValid(phoneNumber string) bool
- func MathRandomConfig() *base64Captcha.DriverMath
- func RandomString(length int) string
- func RemoveSpacesAndTranslate(input string) string
- func TIF[T any](t bool, a1 T, a2 T) T
- func TranslateEn(input string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateRandomKey ¶
func GetIDButNotNumber ¶
GetIDButNotNumber 生成Cube ID前缀, 2024JIAY 需要自行补充数字
func IsEmailValid ¶
func IsPhoneNumberValid ¶
func MathRandomConfig ¶
func MathRandomConfig() *base64Captcha.DriverMath
MathRandomConfig 生成图形化算术验证码配置
func RandomString ¶
func RemoveSpacesAndTranslate ¶
RemoveSpacesAndTranslate 将输入字符串中的空格移除,并将中文字符翻译成拼音后截取前四位英文
func TranslateEn ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.