fs

package
v2.0.5+incompatible Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2018 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Path    string
	AbsPath string
}

Client is the struct for POSIX file system endpoint.

func New

func New(ctx context.Context, et uint8) (c *Client, err error)

New will create a Fs.

func (*Client) Deletable

func (c *Client) Deletable() bool

Deletable implement destination.Deletable

func (*Client) Delete

func (c *Client) Delete(ctx context.Context, p string) (err error)

Delete implement destination.Delete

func (*Client) Fetch

func (c *Client) Fetch(ctx context.Context, p, url string) (err error)

Fetch implement destination.Fetch

func (*Client) Fetchable

func (c *Client) Fetchable() bool

Fetchable implement destination.Fetchable

func (*Client) InitPart

func (c *Client) InitPart(ctx context.Context, p string, size int64) (uploadID string, partSize int64, partNumbers int, err error)

InitPart implement destination.InitPart

func (*Client) List

func (c *Client) List(ctx context.Context, j *model.DirectoryObject, fn func(o model.Object)) (err error)

List implement source.List

func (*Client) Name

func (c *Client) Name(ctx context.Context) (name string)

Name implement base.Read

func (*Client) Partable

func (c *Client) Partable() bool

Partable implement destination.Partable

func (*Client) Reach

func (c *Client) Reach(ctx context.Context, p string) (url string, err error)

Reach implement source.Fetch

func (*Client) Reachable

func (c *Client) Reachable() bool

Reachable implement source.Reachable

func (*Client) Read

func (c *Client) Read(ctx context.Context, p string) (r io.Reader, err error)

Read implement source.Read

func (*Client) ReadRange

func (c *Client) ReadRange(
	ctx context.Context, p string, offset, size int64,
) (r io.Reader, err error)

ReadRange implement source.ReadRange

func (*Client) Stat

func (c *Client) Stat(ctx context.Context, p string) (o *model.SingleObject, err error)

Stat implement source.Stat and destination.Stat

func (*Client) UploadPart

func (c *Client) UploadPart(ctx context.Context, o *model.PartialObject, r io.Reader) (err error)

UploadPart implement destination.UploadPart

func (*Client) Writable

func (c *Client) Writable() bool

Writable implement destination.Writable

func (*Client) Write

func (c *Client) Write(ctx context.Context, p string, _ int64, r io.Reader) (err error)

Write implement destination.Write

Jump to

Keyboard shortcuts

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