hlfabric

package module
v0.0.0-...-4eed6af Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2022 License: MPL-2.0 Imports: 8 Imported by: 1

Documentation

Overview

Package hlfabric contains an implementation of the `gokv.Store` interface for Hyperledger Fabric blockchain.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppUser

type AppUser struct {
	Name    string
	MspPath string
}

AppUser defines hlfabric app user

type Client

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

Client represents hyperledger fabric blockchain client

func NewClient

func NewClient(cfg *Options) (*Client, error)

You must call the Close() method on the client when you're done working with it.

func (*Client) Close

func (c *Client) Close() error

func (*Client) Delete

func (c *Client) Delete(k string) error

func (*Client) Evaluate

func (c *Client) Evaluate(fn string, args ...string) ([]byte, error)

Evaluate will evaluate a transaction function and return its results

func (*Client) Get

func (c *Client) Get(k string, v interface{}) (found bool, err error)

func (*Client) Set

func (c *Client) Set(k string, v interface{}) error

func (*Client) Submit

func (c *Client) Submit(fn string, args ...string) ([]byte, error)

Submit will submit a transaction to the ledger

type Options

type Options struct {
	ChannelName    string
	ContractID     string
	MspID          string
	WalletPath     string
	CcpPath        string
	AppUser        AppUser
	EndorsingPeers []string
}

Options are the options for the HLFabric client

Directories

Path Synopsis
chaincode
kvstore/go Module

Jump to

Keyboard shortcuts

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