Documentation ¶
Index ¶
- Variables
- func CopyFile(old, new string) error
- func CopyN(writer io.Writer, src io.Reader, size int64) (int64, error)
- func CreateFile(filename string, perm os.FileMode) (*os.File, error)
- func CreatePath(path string) error
- func DecodeFileModifyTime(filename string, lastModifyTime int64, decoder DecodeFunc) (int64, interface{}, error)
- func DirEmpty(path string) bool
- func IsDir(f string) int
- func IsExist(f string) bool
- func IsFile(f string) bool
- func MD5(filename string) string
- func MD5Byte(src io.Reader) []byte
- func MD5ByteSize(src io.Reader) ([]byte, int64)
- func MD5Reader(src io.Reader) string
- func MD5Size(src io.Reader) (string, int64)
- func Open(filename string) (*os.File, int64, error)
- func Read(f io.Reader, size int) ([]byte, error)
- func ReadDir(path string, depth *Depth, ...) error
- func ReadFile(f *os.File) ([]byte, error)
- func ReadFileModifyTime(filename string, lastModifyTime int64) (int64, []byte, error)
- func ReadFileName(filename string, reader func(r io.Reader) error) (int64, error)
- func Write(filename string, src io.Reader, perm os.FileMode) error
- func WriteFileName(filename string, perm os.FileMode, writer func(w io.Writer) error) error
- type DecodeFunc
- type Depth
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotModified = errors.New("file not modified")
Functions ¶
func CreateFile ¶ added in v1.8.68
func CreatePath ¶ added in v1.6.11
func DecodeFileModifyTime ¶ added in v1.8.65
func DecodeFileModifyTime(filename string, lastModifyTime int64, decoder DecodeFunc) (int64, interface{}, error)
func MD5ByteSize ¶ added in v1.8.75
MD5ByteSize return md5 bytes and file's size
func ReadDir ¶ added in v1.8.69
func ReadDir(path string, depth *Depth, handler func(name string, isDir bool, entry os.DirEntry) int) error
ReadDir handler return 1: ignore, 0: ok, other: err
func ReadFileModifyTime ¶ added in v1.8.65
func ReadFileName ¶ added in v1.8.68
Types ¶
type DecodeFunc ¶ added in v1.8.65
Click to show internal directories.
Click to hide internal directories.