Documentation ¶
Index ¶
- func AppendFile(filePath string, b []byte) error
- func Basename(fp string) string
- func Dir(fp string) string
- func DirsUnder(dirPath string) ([]string, error)
- func FilesUnder(dirPath string) ([]string, error)
- func GetCurrentAbPath() string
- func GetCurrentAbPathByExecutable() string
- func GetCurrentFuncNameByCaller() string
- func InsureDir(fp string) error
- func IsExist(fp string) bool
- func IsFile(fp string) bool
- func MD5(file string) (string, error)
- func Md5Byte(p []byte) (string, error)
- func OpenLogFile(fp string) (*os.File, error)
- func ReadBytes(cpath string) ([]byte, error)
- func ReadJson(cpath string, cptr interface{}) error
- func ReadString(cpath string) (string, error)
- func ReadStringTrim(cpath string) (string, error)
- func ReadYaml(cpath string, cptr interface{}) error
- func RealPath(fp string) (string, error)
- func Remove(filename string) error
- func SelfDir() string
- func SelfPath() string
- func WriteBytes(filePath string, b []byte) (int, error)
- func WriteString(filePath, s string) (int, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetCurrentAbPathByExecutable ¶
func GetCurrentAbPathByExecutable() string
GetCurrentAbPathByExecutable 当前执行文件目录
func GetCurrentFuncNameByCaller ¶
func GetCurrentFuncNameByCaller() string
GetCurrentFuncNameByCaller 当前方法执行函数名
func IsFile ¶
IsFile checks whether the path is a file, it returns false when it's a directory or does not exist.
func ReadString ¶
func ReadStringTrim ¶
func WriteString ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.