ipfs

package
v3.39.1 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2024 License: AGPL-3.0 Imports: 10 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToFiles

func ToFiles(dstDir string) shell.AddOpts

Types

type Addition

type Addition struct {
	// Usually one of two
	driver.RootPath
	Endpoint string `json:"endpoint" default:"http://127.0.0.1:5001"`
	Gateway  string `json:"gateway" default:"https://ipfs.io"`
}

type IPFS

type IPFS struct {
	model.Storage
	Addition
	// contains filtered or unexported fields
}

func (*IPFS) Config

func (d *IPFS) Config() driver.Config

func (*IPFS) Copy

func (d *IPFS) Copy(ctx context.Context, srcObj, dstDir model.Obj) error

func (*IPFS) Drop

func (d *IPFS) Drop(ctx context.Context) error

func (*IPFS) GetAddition

func (d *IPFS) GetAddition() driver.Additional

func (*IPFS) Init

func (d *IPFS) Init(ctx context.Context) error
func (d *IPFS) Link(ctx context.Context, file model.Obj, args model.LinkArgs) (*model.Link, error)

func (*IPFS) List

func (d *IPFS) List(ctx context.Context, dir model.Obj, args model.ListArgs) ([]model.Obj, error)

func (*IPFS) MakeDir

func (d *IPFS) MakeDir(ctx context.Context, parentDir model.Obj, dirName string) error

func (*IPFS) Move

func (d *IPFS) Move(ctx context.Context, srcObj, dstDir model.Obj) error

func (*IPFS) Put

func (d *IPFS) Put(ctx context.Context, dstDir model.Obj, stream model.FileStreamer, up driver.UpdateProgress) error

func (*IPFS) Remove

func (d *IPFS) Remove(ctx context.Context, obj model.Obj) error

func (*IPFS) Rename

func (d *IPFS) Rename(ctx context.Context, srcObj model.Obj, newName string) error

Jump to

Keyboard shortcuts

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