typedef.go 533 B

123456789101112131415161718192021
  1. package bokofs
  2. import (
  3. "context"
  4. "os"
  5. "golang.org/x/net/webdav"
  6. )
  7. /*
  8. FlowRouter
  9. This interface is used to define the flow of the file system
  10. */
  11. type FlowRouter interface {
  12. Mkdir(ctx context.Context, name string, perm os.FileMode) error
  13. OpenFile(ctx context.Context, name string, flag int, perm os.FileMode) (webdav.File, error)
  14. RemoveAll(ctx context.Context, name string) error
  15. Rename(ctx context.Context, oldName, newName string) error
  16. Stat(ctx context.Context, name string) (os.FileInfo, error)
  17. }