mockbcinfo

package
v0.2.17-metrics Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2018 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BCInfo

func BCInfo(blockHeight uint64) *cb.BlockchainInfo

BCInfo returns a BlockchainInfo with the given block height

Types

type ChannelBCInfo

type ChannelBCInfo struct {
	ChannelID string
	BCInfo    *cb.BlockchainInfo
}

ChannelBCInfo contains a BlockchainInfo for a given channel

func ChannelBCInfos

func ChannelBCInfos(bcInfo ...*ChannelBCInfo) []*ChannelBCInfo

ChannelBCInfos returns an array of ChannelBCInfo

func NewChannelBCInfo

func NewChannelBCInfo(channelID string, bcInfo *cb.BlockchainInfo) *ChannelBCInfo

NewChannelBCInfo returns a new ChannelBCInfo

type MockBlockchainInfoProvider

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

MockBlockchainInfoProvider provides mock BlockchainInfo

func NewProvider

func NewProvider(bcInfo ...*ChannelBCInfo) *MockBlockchainInfoProvider

NewProvider returns a new MockBlockchainInfoProvider

func (*MockBlockchainInfoProvider) GetBlockchainInfo

func (l *MockBlockchainInfoProvider) GetBlockchainInfo(channelID string) (*cb.BlockchainInfo, error)

GetBlockchainInfo returns basic info about blockchain

Jump to

Keyboard shortcuts

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