integrity

package
v2.6.0-beta.3 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	InvalidRecordError     = "Record error: Invalid record"
	RecordNotFoundError    = "Infrastructure error: Http Client error: Request error - API connected by HttpClient found an error: record not found"
	WaitAnchorTimeoutError = "Anchor error: Wait Anchor timed out"
	AnchorNotFoundError    = "Infrastructure error: Http Client error: API connected by HttpClient found an error: anchor not found"
)

Variables

This section is empty.

Functions

func ListOfNetworks

func ListOfNetworks() networks

func NetworkToProto

func NetworkToProto(network Network) *proto.Network

Types

type Anchor

type Anchor struct {
	Id         int64
	BlockRoots []string
	Networks   []AnchorNetwork
	Root       string
	Status     string
}

func NewAnchorFromProto

func NewAnchorFromProto(a *proto.Anchor) Anchor

type AnchorNetwork

type AnchorNetwork struct {
	Name   string
	State  string
	TxHash string
}

func MapAnchorNetworksFromProto

func MapAnchorNetworksFromProto(n []*proto.AnchorNetwork) []AnchorNetwork

func NewAnchorNetworkFromProto

func NewAnchorNetworkFromProto(a *proto.AnchorNetwork) AnchorNetwork

func (AnchorNetwork) ToProto

func (a AnchorNetwork) ToProto() *proto.AnchorNetwork

type AnchorParams

type AnchorParams struct {
	Timeout int64
}

func NewAnchorParams

func NewAnchorParams() AnchorParams

type Network

type Network = proto.Network

type NetworkParams

type NetworkParams struct {
	Network Network
}

func NewNetworkParams

func NewNetworkParams() NetworkParams

type Proof

type Proof struct {
	Leaves []string
	Nodes  []string
	Depth  string
	Bitmap string
	Anchor ProofAnchor
}

func NewProofFromProto

func NewProofFromProto(p *proto.Proof) Proof

func (Proof) ToProto

func (p Proof) ToProto() *proto.Proof

type ProofAnchor

type ProofAnchor struct {
	AnchorID int64
	Networks []AnchorNetwork
	Root     string
	Status   string
}

func NewProofAnchorFromProto

func NewProofAnchorFromProto(p *proto.ProofAnchor) ProofAnchor

func (ProofAnchor) ToProto

func (p ProofAnchor) ToProto() *proto.ProofAnchor

type RecordReceipt

type RecordReceipt struct {
	Anchor int64
	Client string
	Record string
	Status string
}

func NewRecordReceiptFromProto

func NewRecordReceiptFromProto(r *proto.RecordReceipt) RecordReceipt

Jump to

Keyboard shortcuts

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