state

package
v0.0.0-...-7b10863 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const VerifiableCredentialsPrefix = "verifiable:credentials"

VerifiableCredentialsPrefix ...

Variables

View Source
var (

	// NameSpaceMngr ...
	NameSpaceMngr *utils.NamespaceMngr
)

Functions

func CredentialAddress

func CredentialAddress(credential *credential_pb.Credential) string

Types

type State

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

State ...

func NewCredentialState

func NewCredentialState(context *processor.Context) *State

NewCredentialState ...

func (*State) Context

func (s *State) Context() *processor.Context

Context ...

func (*State) GetTxtRecpt

func (s *State) GetTxtRecpt(rpcMethod credential_pb.CredentialIssuingMethod, stateAddress string, credential *credential_pb.Credential) (*credential_pb.IssuingEngineReceipt, []byte, error)

GetTxtRecpt returns a transaction receipt with correct data

func (*State) GetVerifications

func (s *State) GetVerifications(address ...string) ([]*credential_pb.Credential, error)

GetVerifications get some credentials stored at each specified address from state

func (*State) Revoke

func (s *State) Revoke(addresses ...string) error

Revoke revoke credentials stored at each address

func (*State) Save

func (s *State) Save(credential *credential_pb.Credential) error

Save saves a template template to state

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳