Documentation ¶
Index ¶
- Constants
- type FS
- type File
- func (f *File) Close() error
- func (f *File) IsDir() bool
- func (f *File) ModTime() time.Time
- func (f *File) Mode() fs.FileMode
- func (f *File) Name() string
- func (f *File) Read(p []byte) (n int, err error)
- func (f *File) ReadOnly() bool
- func (f *File) Size() int64
- func (f *File) Stat() (fs.FileInfo, error)
- func (f *File) String() string
- func (f *File) Sys() any
- func (f *File) Write(p []byte) (n int, err error)
- type FileOption
Constants ¶
View Source
const (
// In WASI, the path separator is always `/`. https://wa.dev/wasi:filesystem
PathSeparator = '/'
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FS ¶
type FS struct {
// contains filtered or unexported fields
}
FS is a simple in-memory file system that allows for read and write access to files. It's inspired by embed.FS from the standard library. It should be safe for concurrent use. Only top level files are supported, directories are not.
Click to show internal directories.
Click to hide internal directories.