storage

package
v0.0.0-...-8a61e0c Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2020 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnableDebug

func EnableDebug(b bool)

Types

type IPFS

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

func NewIPFS

func NewIPFS(connection string) (instance *IPFS)

func (*IPFS) IsReachable

func (ip *IPFS) IsReachable() bool

func (*IPFS) Load

func (ip *IPFS) Load(address common.StorageAddress) (content string, err error)

func (*IPFS) Store

func (ip *IPFS) Store(content string) (address common.StorageAddress, err error)

type Redis

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

func NewRedis

func NewRedis(connection string, password string) (instance *Redis)

func (*Redis) FlushRedis

func (r *Redis) FlushRedis() (err error)

func (*Redis) IsReachable

func (r *Redis) IsReachable() (reachable bool, err error)

func (*Redis) Load

func (r *Redis) Load(address common.StorageAddress) (content string, err error)

func (*Redis) Store

func (r *Redis) Store(content string) (address common.StorageAddress, err error)

type Storage

type Storage interface {
	Store(content string) (address common.StorageAddress, err error)
	Load(address common.StorageAddress) (content string, err error)
}

Jump to

Keyboard shortcuts

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