os

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2022 License: Apache-2.0 Imports: 7 Imported by: 15

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FS

type FS struct {
	// contains filtered or unexported fields
}

FS wraps the 'os' package as an FS implementation.

func NewFS

func NewFS() *FS

NewFS returns a new FS. All file paths are relative to the root path ('/' on Unix). Use fs.Sub() to select a different root path.

func (*FS) Chmod

func (fs *FS) Chmod(name string, mode hackpadfs.FileMode) error

Chmod implements hackpadfs.ChmodFS

func (*FS) Chown

func (fs *FS) Chown(name string, uid, gid int) error

Chown implements hackpadfs.ChownFS

func (*FS) Chtimes

func (fs *FS) Chtimes(name string, atime time.Time, mtime time.Time) error

Chtimes implements hackpadfs.ChtimesFS

func (*FS) Create

func (fs *FS) Create(name string) (hackpadfs.File, error)

Create implements hackpadfs.CreateFS

func (*FS) Lstat

func (fs *FS) Lstat(name string) (hackpadfs.FileInfo, error)

Lstat implements hackpadfs.LstatFS

func (*FS) Mkdir

func (fs *FS) Mkdir(name string, perm hackpadfs.FileMode) error

Mkdir implements hackpadfs.MkdirFS

func (*FS) MkdirAll

func (fs *FS) MkdirAll(path string, perm hackpadfs.FileMode) error

MkdirAll implements hackpadfs.MkdirAllFS

func (*FS) Open

func (fs *FS) Open(name string) (hackpadfs.File, error)

Open implements hackpadfs.FS

func (*FS) OpenFile

func (fs *FS) OpenFile(name string, flag int, perm hackpadfs.FileMode) (hackpadfs.File, error)

OpenFile implements hackpadfs.OpenFileFS

func (*FS) ReadDir

func (fs *FS) ReadDir(name string) ([]hackpadfs.DirEntry, error)

ReadDir implements hackpadfs.ReadDirFS

func (*FS) ReadFile

func (fs *FS) ReadFile(name string) ([]byte, error)

ReadFile implements hackpadfs.ReadFile

func (*FS) Remove

func (fs *FS) Remove(name string) error

Remove implements hackpadfs.RemoveFS

func (*FS) RemoveAll

func (fs *FS) RemoveAll(name string) error

RemoveAll implements hackpadfs.RemoveAllFS

func (*FS) Rename

func (fs *FS) Rename(oldname, newname string) error

Rename implements hackpadfs.RenameFS

func (*FS) Stat

func (fs *FS) Stat(name string) (hackpadfs.FileInfo, error)

Stat implements hackpadfs.StatFS

func (*FS) Sub

func (fs *FS) Sub(dir string) (hackpadfs.FS, error)

Sub implements hackpadfs.SubFS

func (fs *FS) Symlink(oldname, newname string) error

Symlink implements hackpadfs.SymlinkFS

Jump to

Keyboard shortcuts

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