Documentation
¶
Index ¶
- type LocalFileSystem
- func (*LocalFileSystem) CountDirContents(name string) (int, error)
- func (*LocalFileSystem) Open(name string) (fs.File, error)
- func (*LocalFileSystem) ReadDir(name string) ([]fs.DirEntry, error)
- func (*LocalFileSystem) ReadLink(name string) (string, error)
- func (*LocalFileSystem) Stat(name string) (fs.FileInfo, error)
- func (*LocalFileSystem) UserHomeDir() (string, error)
- func (*LocalFileSystem) WorkDir() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LocalFileSystem ¶
type LocalFileSystem struct {
paths.LocalFilePath
}
FS implements the fs.FS interface.
func NewLocalFileSystem ¶
func NewLocalFileSystem() *LocalFileSystem
func (*LocalFileSystem) CountDirContents ¶
func (*LocalFileSystem) CountDirContents(name string) (int, error)
CountDirContents: returns the number of files/directories direnctly under a given directory
func (*LocalFileSystem) Open ¶
func (*LocalFileSystem) Open(name string) (fs.File, error)
Open opens the named object for reading.
func (*LocalFileSystem) ReadDir ¶
func (*LocalFileSystem) ReadDir(name string) ([]fs.DirEntry, error)
ReadDir reads the directory and returns a list of DirEntry.
func (*LocalFileSystem) ReadLink ¶
func (*LocalFileSystem) ReadLink(name string) (string, error)
ReadLink returns the destination of the named symbolic link. If there is an error, it will be of type *os.PathError.
func (*LocalFileSystem) Stat ¶
func (*LocalFileSystem) Stat(name string) (fs.FileInfo, error)
Stat returns a FileInfo for the given name.
func (*LocalFileSystem) UserHomeDir ¶
func (*LocalFileSystem) UserHomeDir() (string, error)
UserHomeDir returns the current user's home directory.
func (*LocalFileSystem) WorkDir ¶
func (*LocalFileSystem) WorkDir() string
WorkDir returns the path of working directory
Click to show internal directories.
Click to hide internal directories.