Documentation ¶
Index ¶
- func Bool2YN(target bool) string
- func CRC32Hash(str string) string
- func CallerInfo(callstack int) (string, int)
- func CallerInfo2(callstack int) (file string, funcName string, line int)
- func CheckInArray(str string, array []string) bool
- func CheckServIsOn(host, port string, wait time.Duration) bool
- func CheckSign(resData string, targetSign string, md5Key string) bool
- func CreateRandomID_24(salt string) string
- func CreateRandomID_32(salt string) string
- func CreateRandomID_Any(n int) string
- func CreateRandomID_AnySalt(salt string, n int) string
- func DotNetQueryEscape(str string) string
- func GetEncrypt(signStr string, rsaPublicKey string) string
- func GetFunctionName(i interface{}) string
- func GetMemeryUseKB() uint64
- func GetMicroUnixTime(_t time.Time) int64
- func GetSign(signStr string, md5Key string) string
- func HexToCarry(hex string, carry int) string
- func IsJSONString(str string) bool
- func IsJSONStringV2(str string) bool
- func IsTemporary(err error) bool
- func IsTimeout(err error) bool
- func JSONAutoUnmarshal(str string, v interface{}) error
- func JSONFileUnmarshal(path string, v interface{}) error
- func MD5hash(str string) string
- func NowMicroUnixTime() int64
- func NumOnly(str string) (int64, error)
- func OnlyQueryEscapeToLower(str string) string
- func PaySign(privateKeyString string, mReq map[string]interface{}) string
- func PrintSelfName() string
- func PrivateEncryptMD5withRSA(data string, privt *rsa.PrivateKey) (string, error)
- func RsaSign(origData string, privateKey *rsa.PrivateKey) (string, error)
- func SHA1Hash(s string) string
- func SHA256Hash(s string) string
- func StructPrint(_struct interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckServIsOn ¶
CheckServIsOn : 確認伺服器啟動狀態
func CreateRandomID_24 ¶
CreateRandomID_24 : 開頭用hash的隨機數(長度共24字)
func CreateRandomID_32 ¶
CreateRandomID_32 : 開頭用hash的隨機數(長度共32字)
func CreateRandomID_AnySalt ¶
CreateRandomID_AnySalt : 開頭用hash的隨機數(可指定長度)
func DotNetQueryEscape ¶
DotNetQueryEscape : 以 ASP.NET 方式轉換 QueryEscape
func GetEncrypt ¶
func GetFunctionName ¶
func GetFunctionName(i interface{}) string
GetFunctionName : 丟入整個func轉出該func的名字
func GetMicroUnixTime ¶
GetMicroUnixTime : 將時間轉為毫秒(ms) unixtime
func HexToCarry ¶
func JSONAutoUnmarshal ¶
JSONAutoUnmarshal : 自動判斷是 JSON 字串或檔案並轉為 Struct
func JSONFileUnmarshal ¶
JSONFileUnmarshal : 將JSON檔案轉為Struct
func PrivateEncryptMD5withRSA ¶
func PrivateEncryptMD5withRSA(data string, privt *rsa.PrivateKey) (string, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.