indyclient

package module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2020 License: Apache-2.0 Imports: 17 Imported by: 0

README

indyclient

An (almost) pure Go client for the Indy blockchain

It does depend on package github.com/pebbe/zmq4, which uses cgo to call into libzmq. All of the Indy-specific messages and (eventually) crypto will stay in Go, as opposed to linking against libindy.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SovrinPool added in v0.0.2

func SovrinPool(which string) io.Reader

Types

type Block

type Block struct {
	Txn         Txn
	TxnMetadata TxnMetadata
	Ver         int
}

type DataDest

type DataDest struct {
	Data json.RawMessage
	Dest string
}

type Did

type Did struct {
	Method string
	Id     string
}

func DidParse

func DidParse(didStr string) (*Did, error)

type LedgerId

type LedgerId int
const (
	PoolLedger   LedgerId = 0
	DomainLedger LedgerId = 0
)

type Pool

type Pool struct {
	Validators []Validator
	// contains filtered or unexported fields
}

func NewPool

func NewPool(genesis io.Reader) (*Pool, error)

NewPool constructs a new Pool, which will follow the ledgers maintained by the validators in the genesis transactions read from genesis.

func (*Pool) GetTransaction

func (p *Pool) GetTransaction(ledger LedgerId, seqNo int) (*Reply, error)

type Reply

type Reply struct {
	Identifier string `json:"identifier"`
	Op         string `json:"op"`
	ReqId      seqNo  `json:"reqId"`
	Result     json.RawMessage
}

type Txn

type Txn struct {
	Data     DataDest
	Metadata map[string]string
	Type     protoId
}

type TxnData

type TxnData struct {
	Data string
	Dest string
}

type TxnMetadata

type TxnMetadata struct {
	SeqNo int
	TxnId string
}

type TxnNode

type TxnNode struct {
	Alias      string
	ClientIP   string `json:"client_ip"`
	ClientPort string `json:"client_port",string`
}

type Validator

type Validator struct {
	Alias   string
	VerKey  string
	Address string // client_ip:client_port
}

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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