store

package
v0.0.0-...-31ad618 Latest Latest
Warning

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

Go to latest
Published: May 30, 2023 License: Unlicense Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMfsStore

func NewMfsStore(rootDir string, ipfs *shell.Shell) *mfsStore

func NewPgRooter

func NewPgRooter(id string, db *sql.DB) *pgRooter

func NewPinstore

func NewPinstore(ipfs *shell.Shell, rooter Rooter) (*pinstore, error)

func NewQuickStore

func NewQuickStore(shell *shell.Shell) *quickStore

Types

type NullStorage

type NullStorage struct{}

func (*NullStorage) Remove

func (n *NullStorage) Remove(src string) error

func (*NullStorage) Root

func (n *NullStorage) Root() string

func (*NullStorage) Store

func (n *NullStorage) Store(cid, destination string) error

type Rooter

type Rooter interface {
	Lock() error
	Unlock(*error) error

	Root() (string, error)
	UpdateRoot(string) error
}

type Storage

type Storage interface {
	// Store a cid in destination
	Store(cid, destination string) error
	// Remove file
	Remove(src string) error
	// Get root cid
	Root() string
}

Jump to

Keyboard shortcuts

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