tools

package
v0.0.0-...-303b437 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2019 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 4 more Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDBReader

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

func UnmarshalGeneric

func UnmarshalGeneric(i interfaces.BinaryMarshallable, raw []byte) error

Types

type APIReader

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

func NewAPIReader

func NewAPIReader(loc string) *APIReader

func (*APIReader) FetchABlockByHeight

func (a *APIReader) FetchABlockByHeight(height uint32) (interfaces.IAdminBlock, error)

func (*APIReader) FetchDBlockByHeight

func (a *APIReader) FetchDBlockByHeight(height 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) FetchECBlockByHeight

func (a *APIReader) FetchECBlockByHeight(height uint32) (interfaces.IEntryCreditBlock, error)

func (*APIReader) FetchECBlockByPrimary

func (a *APIReader) FetchECBlockByPrimary(keymr interfaces.IHash) (interfaces.IEntryCreditBlock, error)

func (*APIReader) FetchEntry

func (a *APIReader) FetchEntry(hash interfaces.IHash) (interfaces.IEBEntry, error)

func (*APIReader) FetchFBlockByHeight

func (a *APIReader) FetchFBlockByHeight(height uint32) (interfaces.IFBlock, 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 {
	SetChainHeads(primaryIndexes, chainIDs []interfaces.IHash) error
	FetchDBlockHead() (interfaces.IDirectoryBlock, error)
	//FetchDBlock(hash interfaces.IHash) (interfaces.IDirectoryBlock, error)
	FetchHeadIndexByChainID(chainID interfaces.IHash) (interfaces.IHash, error)
	FetchEBlock(hash interfaces.IHash) (interfaces.IEntryBlock, error)

	FetchEntry(hash interfaces.IHash) (interfaces.IEBEntry, error)
	FetchDBlockByHeight(dBlockHeight uint32) (interfaces.IDirectoryBlock, error)
	FetchABlockByHeight(blockHeight uint32) (interfaces.IAdminBlock, error)
	FetchFBlockByHeight(blockHeight uint32) (interfaces.IFBlock, error)
	FetchECBlockByHeight(blockHeight uint32) (interfaces.IEntryCreditBlock, error)
	FetchECBlockByPrimary(keymr interfaces.IHash) (interfaces.IEntryCreditBlock, error)
}

Jump to

Keyboard shortcuts

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