mount

package
v0.0.0-...-7219ecc Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2020 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Mount

func Mount(
	client *drive.Client,
	chunkManager *chunk.Manager,
	mountpoint string,
	mountOptions []string,
	uid, gid uint32,
	umask os.FileMode) error

Mount the fuse volume

func Unmount

func Unmount(mountpoint string, notify bool) error

Unmount unmounts the mountpoint

Types

type FS

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

FS the fuse filesystem

func (*FS) Root

func (f *FS) Root() (fs.Node, error)

Root returns the root path

type Object

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

Object represents one drive object

func (*Object) Attr

func (o *Object) Attr(ctx context.Context, attr *fuse.Attr) error

Attr returns the attributes for a directory

func (*Object) Lookup

func (o *Object) Lookup(ctx context.Context, name string) (fs.Node, error)

Lookup tests if a file is existent in the current directory

func (*Object) Mkdir

func (o *Object) Mkdir(ctx context.Context, req *fuse.MkdirRequest) (fs.Node, error)

Mkdir creates a new directory

func (*Object) Open

func (o *Object) Open(ctx context.Context, req *fuse.OpenRequest, resp *fuse.OpenResponse) (fs.Handle, error)

Open a file

func (*Object) Read

func (o *Object) Read(ctx context.Context, req *fuse.ReadRequest, resp *fuse.ReadResponse) error

Read reads some bytes or the whole file

func (*Object) ReadDirAll

func (o *Object) ReadDirAll(ctx context.Context) ([]fuse.Dirent, error)

ReadDirAll shows all files in the current directory

func (*Object) Remove

func (o *Object) Remove(ctx context.Context, req *fuse.RemoveRequest) error

Remove deletes an element

func (*Object) Rename

func (o *Object) Rename(ctx context.Context, req *fuse.RenameRequest, newDir fs.Node) error

Rename renames an element

Jump to

Keyboard shortcuts

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