common

package
v1.0.0-preview Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2017 License: Apache-2.0 Imports: 20 Imported by: 0 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

View Source
const UndefinedParamValue = ""

UndefinedParamValue defines what undefined parameters in the command line will initialise to

Variables

This section is empty.

Functions

func GetAdminClient

func GetAdminClient() (pb.AdminClient, error)

GetAdminClient returns a new admin client connection for this peer

func GetDefaultSigner

func GetDefaultSigner() (msp.SigningIdentity, error)

GetDefaultSigner return a default Signer(Default/PERR) for cli

func GetEndorserClient

func GetEndorserClient() (pb.EndorserClient, error)

GetEndorserClient returns a new endorser client connection for this peer

func GetMockEndorserClient

func GetMockEndorserClient(response *pb.ProposalResponse, err error) pb.EndorserClient

GetMockEndorserClient return a endorser client return specified ProposalResponse and err(nil or error)

func InitConfig

func InitConfig(cmdRoot string) error

InitConfig initializes viper config

func InitCrypto

func InitCrypto(mspMgrConfigDir string) error

InitCrypto initializes crypto for this peer

func SetErrorLoggingLevel

func SetErrorLoggingLevel() error

SetErrorLoggingLevel sets the 'error' module's logger to the value in core.yaml

Types

type AnchorPeerParser

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

func GetAnchorPeersParser

func GetAnchorPeersParser(anchorPeerParam string) *AnchorPeerParser

func GetDefaultAnchorPeerParser

func GetDefaultAnchorPeerParser() *AnchorPeerParser

func (*AnchorPeerParser) Parse

func (app *AnchorPeerParser) Parse() ([]*peer.AnchorPeer, error)

type BroadcastClient

type BroadcastClient interface {
	//Send data to orderer
	Send(env *cb.Envelope) error
	Close() error
}

func GetBroadcastClient

func GetBroadcastClient() (BroadcastClient, error)

GetBroadcastClient creates a simple instance of the BroadcastClient interface

func GetMockBroadcastClient

func GetMockBroadcastClient(err error) BroadcastClient

Jump to

Keyboard shortcuts

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