Documentation
¶
Index ¶
- func Base64Decode(str string) (data []byte)
- func Base64Encode(src []byte) (str string)
- func EncryptCenter(source string) string
- func EncryptStr(source string, prefixAmount, suffixAmount int, symbol string) string
- func Exist(targetStr, needleStr string) bool
- func GetAlphabetRank(letter string) (rank int, err error)
- func GetAsciiValue(letter string) (asciiValue int, err error)
- func GetPinyin(zhStr string, style int) (result string)
- func GetPinyinFirstLetter(zhStr string) (result string)
- func GetPinyinFull(zhStr string) (result string)
- func GetRandomNumbers(l int) string
- func GetRandomString(l int) string
- func GetUUID() uuid.UUID
- func GetWordsLength(str string) float64
- func LimitLength(str string, maxLength int) string
- func StripTags(body string) string
- func Substr(s string, start, length int) string
- func Trim(str string) (data string)
- func ValidatePhone(phoneNum string) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncryptCenter ¶ added in v1.5.6
EncryptCenter 用符号替换中间字符,保留首位
func EncryptStr ¶ added in v1.5.6
EncryptStr 用特定符号加密字符串 prefixAmount 前缀加密长度 suffixAmount 后缀加密长度
func GetAlphabetRank ¶ added in v1.5.6
GetAlphabetRank 获取字母的排序(1-26),无论大小写
func GetAsciiValue ¶ added in v1.5.6
GetAsciiValue 获取ascii值(只接受一个值)
func GetPinyinFirstLetter ¶ added in v1.5.6
GetPinyinFirstLetter 获取首字母
func GetPinyinFull ¶ added in v1.5.6
GetPinyinFull 获取拼音全拼
func GetRandomNumbers ¶ added in v1.5.6
GetRandomNumbers 获取指定位数的随机字符串
func LimitLength ¶ added in v1.5.6
LimitLength 限制字符长度
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.