Documentation
¶
Overview ¶
Package webdav brings WebDAV files handling to afero
Index ¶
- Variables
- type File
- func (f *File) Close() error
- func (f *File) Name() string
- func (f *File) Read(p []byte) (int, error)
- func (f *File) ReadAt(p []byte, off int64) (n int, err error)
- func (f *File) Readdir(n int) ([]os.FileInfo, error)
- func (f *File) Readdirnames(n int) ([]string, error)
- func (f *File) Seek(offset int64, whence int) (int64, error)
- func (f *File) Stat() (os.FileInfo, error)
- func (f *File) Sync() error
- func (f *File) Truncate(int64) error
- func (f *File) Write(p []byte) (int, error)
- func (f *File) WriteAt(p []byte, off int64) (n int, err error)
- func (f *File) WriteString(s string) (int, error)
- type FileInfo
- type Fs
- func (fs *Fs) Chmod(name string, mode os.FileMode) error
- func (Fs) Chown(string, int, int) error
- func (Fs) Chtimes(string, time.Time, time.Time) error
- func (fs *Fs) Create(name string) (afero.File, error)
- func (fs *Fs) Mkdir(name string, perm os.FileMode) error
- func (fs *Fs) MkdirAll(name string, perm os.FileMode) error
- func (*Fs) Name() string
- func (fs *Fs) Open(name string) (afero.File, error)
- func (fs *Fs) OpenFile(name string, flag int, perm os.FileMode) (afero.File, error)
- func (fs *Fs) Remove(name string) error
- func (fs *Fs) RemoveAll(name string) error
- func (fs *Fs) Rename(oldname, newname string) error
- func (fs *Fs) Stat(name string) (os.FileInfo, error)
Constants ¶
This section is empty.
Variables ¶
var ErrAlreadyOpened = errors.New("already opened")
ErrAlreadyOpened is returned when the file is already opened.
var ErrInvalidSeek = errors.New("invalid seek offset")
ErrInvalidSeek is returned when the seek operation is not doable.
var ErrNotImplemented = errors.New("not implemented")
ErrNotImplemented is returned when this operation is not (yet) implemented.
var ErrNotSupported = errors.New("webdav doesn't support this operation")
ErrNotSupported is returned when this operations is not supported by WebDAV.
Functions ¶
This section is empty.
Types ¶
type File ¶
type File struct {
// contains filtered or unexported fields
}
File represents a file in WebDAV.
func (*File) Readdirnames ¶
Readdirnames reads and returns a slice of names from the directory f.
type FileInfo ¶
type FileInfo struct {
// contains filtered or unexported fields
}
FileInfo implements os.FileInfo for a file in WebDAV.
func NewFileInfo ¶
NewFileInfo creates file info.
func (FileInfo) Mode ¶
Mode provides the file mode bits. For a file in WebDAV this defaults to 664 for files, 755 for directories.
type Fs ¶
type Fs struct {
// contains filtered or unexported fields
}
Fs is an FS object backed by WebDAV.
func NewFsFromClient ¶
NewFsFromClient creates a new Fs instance from an existing WebDAV client.