Documentation ¶
Overview ¶
* @Author: 2Kil * @Date: 2024-04-19 10:54:20 * @LastEditors: 2Kil * @LastEditTime: 2024-10-20 17:02:20 * @Description:tktar
Index ¶
- func BuildTime() string
- func CheckErr(err error, errString ...string) bool
- func HelperRemoveDuplicates(s []string) []string
- func IsDebug() bool
- func LogFile(logFIle string, systemLog string) (*logger.Logger, error)
- func NetCurl(curlBash string) (int, string)
- func NetParseCurlComd(curlCmd string) (string, string, http.Header, []byte, error)
- func NetProxyCurl(proxy, curlBash string) (int, string)
- func RandAtomic(max int) int
- func RandAtomicRadius(min, max int) int
- func SysGetSerialKey() string
- func TextAesDecrypt(cipherText, key string) string
- func TextAesEncrypt(plainText, key string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckErr ¶
*
- @description: 错误检测
- @param {error} err 错误信息
- @param {string} errString 自定义错误提示
- @return {bool} 无错误true 有错误false
func HelperRemoveDuplicates ¶
*
- @description: 切片去重,去空
- @param {[]string} 待处理的切片
- @return {[]string} 处理后的切片
func IsDebug ¶
func IsDebug() bool
*
- @description: 判断当前环境是否为Debug模式
- @return {bool} true:Debug模式 false:Release模式
func LogFile ¶ added in v1.0.2
*
- @description: 记录日志到文件&系统事件
- @param {string} logFIle
- @param {bool} systemLog true写入系统事件
- @return {*}
func NetCurl ¶ added in v0.1.2
*
- @description:go的curl实现
- @param {string} cUrl(bash)格式的请求命令
- @return {*} 响应体
func NetParseCurlComd ¶ added in v0.1.2
*
- @description: 解析curl命令
- @param {string} curlCmd
- @return {*} 请求方法,请求地址,请求头,请求体,错误信息
func NetProxyCurl ¶ added in v1.0.1
*
- @description:go的curl实现(走代理)
- @param {string} cUrl(bash)格式的请求命令
- @return {*} 响应体
func RandAtomicRadius ¶
*
- @description: 生成范围内的随机数
- @param {int} min 最小值
- @param {int} max 最大值
- @return {int} 随机数
func TextAesDecrypt ¶
*
- @description: aes解密
- @param {string} 待解密的文本
- @param {string} 密钥
- @return {string} 明文
func TextAesEncrypt ¶
*
- @description: aes加密
- @param {string} 待加密的文本
- @param {string} 16,24,32密钥
- @return {string} 密文
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.