vfs

package
v0.0.0-...-a658396 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotImplemented = errors.New("not implemented")

Functions

func NewVFS

func NewVFS(r Store) webdav.FileSystem

NewMemFS returns a new in-memory FileSystem implementation.

Types

type FileInfo

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

func (FileInfo) IsDir

func (fi FileInfo) IsDir() bool

func (FileInfo) ModTime

func (fi FileInfo) ModTime() time.Time

func (FileInfo) Mode

func (fi FileInfo) Mode() os.FileMode

func (FileInfo) Name

func (fi FileInfo) Name() string

func (FileInfo) Size

func (fi FileInfo) Size() int64

func (FileInfo) Sys

func (fi FileInfo) Sys() interface{}

type Store

type Store interface {
	Get() ([]byte, error)
	Set([]byte) error
}

type VFS

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

func (*VFS) Mkdir

func (v *VFS) Mkdir(ctx context.Context, name string, perm os.FileMode) error

func (*VFS) OpenFile

func (fs *VFS) OpenFile(ctx context.Context, name string, flag int, perm os.FileMode) (webdav.File, error)

func (*VFS) RemoveAll

func (fs *VFS) RemoveAll(ctx context.Context, name string) error

func (*VFS) Rename

func (v *VFS) Rename(ctx context.Context, oldName, newName string) error

func (*VFS) Stat

func (fs *VFS) Stat(ctx context.Context, name string) (os.FileInfo, error)

Jump to

Keyboard shortcuts

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