Documentation ¶
Index ¶
- func RegisterEngine(name string, fn NewVFSFunc)
- type File
- type NewVFSFunc
- type ReadOnlyFile
- func (rof *ReadOnlyFile) Chmod(mode os.FileMode) error
- func (rof *ReadOnlyFile) Close() error
- func (rof *ReadOnlyFile) Name() string
- func (rof *ReadOnlyFile) Read(buf []byte) (int, error)
- func (rof *ReadOnlyFile) ReadAt(buf []byte, offset int64) (int, error)
- func (rof *ReadOnlyFile) Readdir(n int) ([]os.FileInfo, error)
- func (rof *ReadOnlyFile) Readdirnames(n int) ([]string, error)
- func (rof *ReadOnlyFile) Stat() (os.FileInfo, error)
- func (rof *ReadOnlyFile) Write(buf []byte) (int, error)
- func (rof *ReadOnlyFile) WriteAt(buf []byte, off int64) (int, error)
- type ReadOnlyVFS
- func (rofs *ReadOnlyVFS) Chmod(name string, mode os.FileMode) error
- func (rofs *ReadOnlyVFS) Close() error
- func (rofs *ReadOnlyVFS) Mkdir(path string, perm os.FileMode) error
- func (rofs *ReadOnlyVFS) Open(path string) (File, error)
- func (rofs *ReadOnlyVFS) OpenFile(name string, flag int, perm os.FileMode) (File, error)
- func (rofs *ReadOnlyVFS) Remove(path string) error
- func (rofs *ReadOnlyVFS) Rename(from, to string) error
- func (rofs *ReadOnlyVFS) Stat(path string) (os.FileInfo, error)
- type VFS
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterEngine ¶
func RegisterEngine(name string, fn NewVFSFunc)
Types ¶
type File ¶
type File interface { Name() string Chmod(mode os.FileMode) error Read(buf []byte) (int, error) ReadAt(buf []byte, offset int64) (int, error) Readdir(n int) ([]os.FileInfo, error) Readdirnames(n int) ([]string, error) Write(buf []byte) (int, error) WriteAt(buf []byte, off int64) (int, error) Stat() (os.FileInfo, error) Close() error }
type NewVFSFunc ¶
type ReadOnlyFile ¶
type ReadOnlyFile struct {
F File
}
func (*ReadOnlyFile) Close ¶
func (rof *ReadOnlyFile) Close() error
func (*ReadOnlyFile) Name ¶
func (rof *ReadOnlyFile) Name() string
func (*ReadOnlyFile) ReadAt ¶
func (rof *ReadOnlyFile) ReadAt(buf []byte, offset int64) (int, error)
func (*ReadOnlyFile) Readdirnames ¶
func (rof *ReadOnlyFile) Readdirnames(n int) ([]string, error)
type ReadOnlyVFS ¶
type ReadOnlyVFS struct {
Fs VFS
}
func (*ReadOnlyVFS) Close ¶
func (rofs *ReadOnlyVFS) Close() error
func (*ReadOnlyVFS) Remove ¶
func (rofs *ReadOnlyVFS) Remove(path string) error
func (*ReadOnlyVFS) Rename ¶
func (rofs *ReadOnlyVFS) Rename(from, to string) error
type VFS ¶
type VFS interface { Chmod(name string, mode os.FileMode) error Open(path string) (File, error) OpenFile(name string, flag int, perm os.FileMode) (File, error) Mkdir(path string, perm os.FileMode) error Stat(path string) (os.FileInfo, error) Rename(from, to string) error Remove(path string) error Close() error }
Click to show internal directories.
Click to hide internal directories.