client

package
v0.0.0-...-8619d99 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2022 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsChannelUnknownErr

func IsChannelUnknownErr(err error) bool

IsChannelUnknownErr checks if the given error indicates the channel is unknown.

func IsUnderfundedErr

func IsUnderfundedErr(err error) bool

IsUnderfundedErr checks if the given error indicates the channel is underfunded.

func NewAccountWithSigner

func NewAccountWithSigner(privateKeyPEMPath string) (identity.Sign, *wallet.Account, error)

NewAccountWithSigner generates a new account and singer based on the given path of the private key file.

func NewGrpcConnection

func NewGrpcConnection(gatewayPeer, peerEndpoint, peerTLSCertPath string) (*grpc.ClientConn, error)

NewGrpcConnection creates a gRPC connection to the Gateway server.

func NewIdentity

func NewIdentity(mspID, certPath string) (*identity.X509Identity, *wallet.Address, adj.AccountID, error)

NewIdentity creates a client identity for a Gateway connection using an X.509 certificate. It also returns the corresponding Fabric backend Address.

func ParseClientErr

func ParseClientErr(err error) string

ParseClientErr parses the full details of err as a fabric client error.

func ReadCertificate

func ReadCertificate(filename string) (*x509.Certificate, error)

ReadCertificate takes the given path to the certificate file, reads it and returns a x509.Certificate.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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