Documentation
¶
Index ¶
- Variables
- func CheckNetworkCableConn(deviceName string) bool
- func Cmd(cmd string) (string, error)
- func Contain(a []interface{}, e interface{}) bool
- func ContainEx(a interface{}, f func(predicate interface{}) bool) bool
- func CreatDir(dirPath string) error
- func GetDiskFreePercent() (string, error)
- func GetDiskFreeSize() (uint64, error)
- func GetDiskTotalSize() (uint64, error)
- func GetDiskUsedSize() (uint64, error)
- func GetIni(section, key string) string
- func GetPrevDir(dirPath string) string
- func GetSizeOfDir(dirPath string) (int64, error)
- func InSlice(ss []string, s string) bool
- func IsPathExist(filePath string) bool
- func MD5(v string) string
- func RandStr(n int) string
- func ReadAll(path string) ([]byte, error)
- func RemoveAll(dirPath string) error
- func RemoveFile(filePath string) error
- func SetIni(section, key, val string) error
- func SuitableDisplaySize(size int64) string
- func Unzip(zipFile string, destDir string) error
- func WriteAll(path string, data []byte) error
- func Zip(srcFile string, destZip string) error
- type CustomClaims
- type JWT
- type Response
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func CheckNetworkCableConn ¶
func GetDiskFreePercent ¶
func GetPrevDir ¶
func IsPathExist ¶
func RemoveFile ¶
func SuitableDisplaySize ¶
Types ¶
type CustomClaims ¶
type CustomClaims struct { Username string jwt.StandardClaims }
type JWT ¶
type JWT struct {
SigningKey []byte
}
func (*JWT) CreateToken ¶
func (j *JWT) CreateToken(claims CustomClaims) string
func (*JWT) ParseToken ¶
func (j *JWT) ParseToken(tokenString string) (*CustomClaims, error)
Click to show internal directories.
Click to hide internal directories.