internal

package
v0.0.0-...-53bb331 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrReadOnly = errors.New("readonly fs")
)

Functions

This section is empty.

Types

type WebDAVFile

type WebDAVFile struct {
	FileSystem fs.FS
	File       fs.File
	FileReader *bytes.Reader
}

func NewWebDAVFile

func NewWebDAVFile(fileSystem fs.FS, file fs.File) (*WebDAVFile, error)

func (*WebDAVFile) Close

func (wf *WebDAVFile) Close() error

func (*WebDAVFile) Read

func (wf *WebDAVFile) Read(p []byte) (n int, err error)

func (*WebDAVFile) Readdir

func (wf *WebDAVFile) Readdir(count int) ([]fs.FileInfo, error)

func (*WebDAVFile) Seek

func (wf *WebDAVFile) Seek(offset int64, whence int) (int64, error)

func (*WebDAVFile) Stat

func (wf *WebDAVFile) Stat() (fs.FileInfo, error)

func (*WebDAVFile) Write

func (wf *WebDAVFile) Write(p []byte) (n int, err error)

type WebDAVFileSystem

type WebDAVFileSystem struct {
	FileSystem fs.FS
}

func NewWebDAVFileSystemFromFS

func NewWebDAVFileSystemFromFS(fileSystem fs.FS) *WebDAVFileSystem

func (*WebDAVFileSystem) Mkdir

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

func (*WebDAVFileSystem) OpenFile

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

func (*WebDAVFileSystem) RemoveAll

func (wfs *WebDAVFileSystem) RemoveAll(ctx context.Context, name string) error

func (*WebDAVFileSystem) Rename

func (wfs *WebDAVFileSystem) Rename(ctx context.Context, oldName, newName string) error

func (*WebDAVFileSystem) Stat

func (wfs *WebDAVFileSystem) 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