webdav

package
v0.17.1 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2024 License: GPL-3.0 Imports: 22 Imported by: 0

README

WEBDAV Plugin

Documentation

Documentation

Index

Constants

View Source
const (
	// Name ...
	Name = "webdav"

	AttrUser      = "user"
	AttrPassword  = "password"
	AttrAnonymous = "anonymous"

	Version = "0.0.1"
)

Variables

Functions

func New

func New() supervisor.Pluggable

New ...

func NewSettings

func NewSettings() m.Attributes

NewSettings ...

Types

type FS

type FS struct {
	afero.Fs
	// contains filtered or unexported fields
}

func NewFS

func NewFS(onRemoveHandler func(context.Context, string) error) *FS

func (*FS) Mkdir

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

func (*FS) OpenFile

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

func (*FS) RemoveAll

func (f *FS) RemoveAll(ctx context.Context, name string) error

func (*FS) Rename

func (f *FS) Rename(ctx context.Context, oldName, newName string) error

func (*FS) Stat

func (f *FS) Stat(ctx context.Context, name string) (os.FileInfo, error)

type FileInfo

type FileInfo struct {
	Size          int64
	ModTime       time.Time
	LastCheck     time.Time
	IsInitialized bool
}

type Scripts

type Scripts struct {
	*FS

	sync.Mutex
	// contains filtered or unexported fields
}

func NewScripts

func NewScripts(fs *FS) *Scripts

func (*Scripts) Shutdown

func (s *Scripts) Shutdown()

func (*Scripts) Start

func (s *Scripts) Start(adaptors *adaptors.Adaptors, scriptService scripts.ScriptService, eventBus bus.Bus)

type Server

type Server struct {
	*FS
	// contains filtered or unexported fields
}

func NewServer

func NewServer() *Server

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)

func (*Server) Shutdown

func (s *Server) Shutdown()

func (*Server) Start

func (s *Server) Start(adaptors *adaptors.Adaptors, scriptService scripts.ScriptService, eventBus bus.Bus)

Jump to

Keyboard shortcuts

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