lessdisk

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: May 17, 2019 License: MIT Imports: 11 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDataSize = errors.New("data size err")
)

Functions

This section is empty.

Types

type ChainOperator

type ChainOperator interface {
	CurrentHeader() *types.Header
	DelLocalBlocks(blocks []*mc.BlockInfo) (fails []*mc.BlockInfo, err error)
}

type DatabaseOperator

type DatabaseOperator interface {
	Has(key []byte) (bool, error)
	Get(key []byte) ([]byte, error)
	Put(key []byte, value []byte) error
	Delete(key []byte) error
}

type Server

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

func NewLessDiskSvr

func NewLessDiskSvr(config *params.LessDiskConfig, db DatabaseOperator, chain ChainOperator) *Server

func (*Server) FuncSwitch

func (self *Server) FuncSwitch(enable bool)

func (*Server) Stop

func (self *Server) Stop()

Jump to

Keyboard shortcuts

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