fs

package
v1.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2024 License: LGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileSystemUtils added in v1.1.0

type FileSystemUtils struct{}

FileSystemUtils 定义文件系统工具类

func NewFileSysUtils added in v1.1.0

func NewFileSysUtils() *FileSystemUtils

func (*FileSystemUtils) CreateDirIfNotExist added in v1.1.0

func (fsu *FileSystemUtils) CreateDirIfNotExist(relativePath string) error

CreateDirIfNotExist 在当前执行文件所在目录下创建指定的目录,如果目录不存在

func (*FileSystemUtils) Delete added in v1.1.0

func (fsu *FileSystemUtils) Delete(path string) error

Delete 删除指定路径的文件或目录

func (*FileSystemUtils) GetAllFilesByExt added in v1.1.0

func (fsu *FileSystemUtils) GetAllFilesByExt(dir string, ext string) ([]string, error)

func (*FileSystemUtils) GetCurExeDir added in v1.1.0

func (fsu *FileSystemUtils) GetCurExeDir() string

func (*FileSystemUtils) GetFileCreationTime added in v1.1.0

func (fsu *FileSystemUtils) GetFileCreationTime(filePath string) (string, time.Time, error)

func (*FileSystemUtils) GetFileMd5 added in v1.1.0

func (fsu *FileSystemUtils) GetFileMd5(filePath string) (string, error)

func (*FileSystemUtils) GetFileMd5Stream added in v1.1.0

func (fsu *FileSystemUtils) GetFileMd5Stream(filePath string) (string, error)

func (*FileSystemUtils) GetFileNameMd5 added in v1.1.0

func (fsu *FileSystemUtils) GetFileNameMd5(filename string) (string, error)

func (*FileSystemUtils) IsDirAndHasFiles added in v1.1.0

func (fsu *FileSystemUtils) IsDirAndHasFiles(dirPath string) (bool, bool, error)

func (*FileSystemUtils) StartsWithDot added in v1.1.0

func (fsu *FileSystemUtils) StartsWithDot(fileName string) bool

StartsWithDot 检查文件名是否以 '.' 开头

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL