tools

package
v6.3.2-rc3+incompatible Latest Latest
Warning

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

Go to latest
Published: May 22, 2019 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 4 more Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDBReader

func NewDBReader(levelBolt string, path string) *databaseOverlay.Overlay

Types

type APIReader

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

func NewAPIReader

func NewAPIReader(loc string) *APIReader

func (*APIReader) FetchDBlockByHeight

func (a *APIReader) FetchDBlockByHeight(dBlockHeight uint32) (interfaces.IDirectoryBlock, error)

func (*APIReader) FetchDBlockHead

func (a *APIReader) FetchDBlockHead() (interfaces.IDirectoryBlock, error)

func (*APIReader) FetchEBlock

func (a *APIReader) FetchEBlock(hash interfaces.IHash) (interfaces.IEntryBlock, error)

func (*APIReader) FetchHeadIndexByChainID

func (a *APIReader) FetchHeadIndexByChainID(chainID interfaces.IHash) (interfaces.IHash, error)

func (*APIReader) SetChainHeads

func (a *APIReader) SetChainHeads(primaryIndexes, chainIDs []interfaces.IHash) error

type Fetcher

type Fetcher interface {
	FetchDBlockHead() (interfaces.IDirectoryBlock, error)
	FetchDBlockByHeight(dBlockHeight uint32) (interfaces.IDirectoryBlock, error)
	//FetchDBlock(hash interfaces.IHash) (interfaces.IDirectoryBlock, error)
	FetchHeadIndexByChainID(chainID interfaces.IHash) (interfaces.IHash, error)
	FetchEBlock(hash interfaces.IHash) (interfaces.IEntryBlock, error)
	SetChainHeads(primaryIndexes, chainIDs []interfaces.IHash) error
}

Able to be either a datbase or api

Jump to

Keyboard shortcuts

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