Documentation ¶
Index ¶
- func GetClientAccessIP(r *http.Request) string
- func GetRoutineId() string
- func IPString2Long(ip string) (uint32, error)
- func InitLogWrapper(maxFileSizeBytes int64, zipLog bool, out2stderr bool)
- func IpCidr2IpRange(ipCidr string) (ipStart, ipEnd string, err error)
- func IsDebug() bool
- func Long2IPString(i uint32) (string, error)
- func Md5sum(src string) string
- func OutDebugInfo() bool
- func ReadDirAscByTime(name string) ([]os.DirEntry, error)
- func ReadDirDescByTime(name string) ([]os.DirEntry, error)
- func SetDebug(debugMode bool)
- func SetOutDebugInfo(outDebugInfo bool)
- func UTCTime() string
- func UnZipTarGzFileToDir(srcFile string, destDir string) error
- func ZipFileToTarGz(srcFile string, destFile string) error
- func ZipFileToTarGzWithLevel(srcFile string, destFile string, zipLevel int) error
- func ZipFilesToTarGz(sliceSrcFile []string, destFile string) error
- func ZipFilesToTarGzWithLevel(sliceSrcDir []string, destFile string, zipLevel int) error
- type CXLogFile
- type LogFunc
- type LogFuncf
- type LogSpeedFunc
- type XRedisClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetRoutineId ¶
func GetRoutineId() string
func IPString2Long ¶
func InitLogWrapper ¶
InitLogWrapper maxFileSizeBytes, 0 is set to 50MB zipLog, zip logs when write to file out2stderr, out to file default
func IpCidr2IpRange ¶
func Long2IPString ¶
func OutDebugInfo ¶
func OutDebugInfo() bool
func SetOutDebugInfo ¶
func SetOutDebugInfo(outDebugInfo bool)
func UnZipTarGzFileToDir ¶
func ZipFileToTarGz ¶
func ZipFileToTarGzWithLevel ¶
func ZipFilesToTarGz ¶
Types ¶
type LogFunc ¶
type LogFunc func(...interface{})
var Debug LogFunc
var Err LogFunc
var Info LogFunc
var Warn LogFunc
type LogFuncf ¶
type LogFuncf func(template string, args ...interface{})
var Debugf LogFuncf
var Errf LogFuncf
var Infof LogFuncf
var Warnf LogFuncf
type LogSpeedFunc ¶
type XRedisClient ¶
type XRedisClient struct {
// contains filtered or unexported fields
}
func NewXRedisClient ¶
func NewXRedisClusterClient ¶
func NewXRedisClusterClient(addrs []string, pwd string, lockName string) (*XRedisClient, error)
func (*XRedisClient) Redis ¶
func (x *XRedisClient) Redis() goredislib.UniversalClient
Click to show internal directories.
Click to hide internal directories.