Documentation
¶
Index ¶
- Constants
- func AesDecrypt(ciphertext []byte, key []byte, iv []byte) ([]byte, error)
- func AesEncrypt(plaintext []byte, key []byte, iv []byte) ([]byte, error)
- func Copy(dst, src interface{}) error
- func FileExist(path string) error
- func FilesExist(path ...string) error
- func GetClientIp(r *http.Request) string
- func Ip2Long(ipStr string) uint32
- func IsPublicIP(IP net.IP) bool
- func Join(s []string, sep string) string
- func NetLong2ip(ip uint32) string
- func ParseGzip(data []byte) ([]byte, error)
- func RandInt32(min, max int32) int32
- func RandInt64(min, max int64) int64
- func RandStr(length int, chars string, mod uint) string
- func Split(s, sep string) []string
- func SubStr(str string, start int, end int) string
- func TimeFormatInLocation(tm time.Time, layout string) string
- func TimeParseInLocation(layout, value string) (time.Time, error)
- func VersionCompare(version1, version2, operator string) bool
Constants ¶
View Source
const ( RandStrModNumber = 0x01 RandStrModUpperCase = 0x02 RandStrModLowerCase = 0x04 )
View Source
const (
TimeFormatYear2Second = "2006-01-02 15:04:05"
)
Variables ¶
This section is empty.
Functions ¶
func FilesExist ¶
func GetClientIp ¶
func IsPublicIP ¶
func NetLong2ip ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.