package mem

Import Path
	github.com/spf13/afero/mem (on go.dev)

Dependency Relation
	imports 9 packages, and imported by one package

Involved Source Files dir.go dirmap.go file.go
Package-Level Type Names (total 6, in which 5 are exported)
/* sort exporteds by: | */
( T) Add(*FileData) ( T) Files() []*FileData ( T) Len() int ( T) Names() []string ( T) Remove(*FileData) DirMap
( T) Add(f *FileData) ( T) Files() (files []*FileData) ( T) Len() int ( T) Names() (names []string) ( T) Remove(f *FileData) T : Dir
(*T) Close() error ( T) Data() *FileData (*T) Info() *FileInfo (*T) Name() string (*T) Open() error (*T) Read(b []byte) (n int, err error) (*T) ReadAt(b []byte, off int64) (n int, err error) (*T) Readdir(count int) (res []os.FileInfo, err error) (*T) Readdirnames(n int) (names []string, err error) (*T) Seek(offset int64, whence int) (int64, error) (*T) Stat() (os.FileInfo, error) (*T) Sync() error (*T) Truncate(size int64) error (*T) Write(b []byte) (n int, err error) (*T) WriteAt(b []byte, off int64) (n int, err error) (*T) WriteString(s string) (ret int, err error) *T : github.com/spf13/afero.File *T : io.Closer *T : io.ReadCloser *T : io.Reader *T : io.ReaderAt *T : io.ReadSeekCloser *T : io.ReadSeeker *T : io.ReadWriteCloser *T : io.ReadWriter *T : io.ReadWriteSeeker *T : io.Seeker *T : io.StringWriter *T : io.WriteCloser *T : io.Writer *T : io.WriterAt *T : io.WriteSeeker *T : io/fs.File *T : mime/multipart.File *T : net/http.File func NewFileHandle(data *FileData) *File func NewReadOnlyFileHandle(data *FileData) *File
Mutex sync.Mutex Lock locks m. If the lock is already in use, the calling goroutine blocks until the mutex is available. (*T) Name() string Unlock unlocks m. It is a run-time error if m is not locked on entry to Unlock. A locked Mutex is not associated with a particular goroutine. It is allowed for one goroutine to lock a Mutex and then arrange for another goroutine to unlock it. *T : sync.Locker func CreateDir(name string) *FileData func CreateFile(name string) *FileData func Dir.Files() []*FileData func DirMap.Files() (files []*FileData) func File.Data() *FileData func AddToMemDir(dir *FileData, f *FileData) func AddToMemDir(dir *FileData, f *FileData) func ChangeFileName(f *FileData, newname string) func GetFileInfo(f *FileData) *FileInfo func InitializeDir(d *FileData) func NewFileHandle(data *FileData) *File func NewReadOnlyFileHandle(data *FileData) *File func RemoveFromMemDir(dir *FileData, f *FileData) func RemoveFromMemDir(dir *FileData, f *FileData) func SetGID(f *FileData, gid int) func SetMode(f *FileData, mode os.FileMode) func SetModTime(f *FileData, mtime time.Time) func SetUID(f *FileData, uid int) func Dir.Add(*FileData) func Dir.Remove(*FileData) func DirMap.Add(f *FileData) func DirMap.Remove(f *FileData)
FileData *FileData FileData.Mutex sync.Mutex (*T) IsDir() bool Lock locks m. If the lock is already in use, the calling goroutine blocks until the mutex is available. (*T) ModTime() time.Time (*T) Mode() os.FileMode Implements os.FileInfo (*T) Size() int64 (*T) Sys() interface{} Unlock unlocks m. It is a run-time error if m is not locked on entry to Unlock. A locked Mutex is not associated with a particular goroutine. It is allowed for one goroutine to lock a Mutex and then arrange for another goroutine to unlock it. *T : io/fs.FileInfo T : sync.Locker func GetFileInfo(f *FileData) *FileInfo func (*File).Info() *FileInfo
Package-Level Functions (total 14, in which 13 are exported)
func AddToMemDir(dir *FileData, f *FileData)
func ChangeFileName(f *FileData, newname string)
func SetGID(f *FileData, gid int)
func SetMode(f *FileData, mode os.FileMode)
func SetModTime(f *FileData, mtime time.Time)
func SetUID(f *FileData, uid int)
Package-Level Variables (total 6, all are exported)
Package-Level Constants (only one, which is exported)