writerhttp

package
Version: v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2020 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrIdenStateNotFound = fmt.Errorf("identity state not found in the cache")
)

Functions

This section is empty.

Types

type Config

type Config struct {
	CacheLen byte
	Url      string
}

func NewConfigDefault

func NewConfigDefault(url string) *Config

type IdenPubOffChainWriteHttp

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

IdenPubOffChainWriteHttp satisfies the IdenPubOffChainWriter interface, and stores in a leveldb the published RootsTree & RevocationsTree to be returned when requested.

func LoadIdenPubOffChainWriteHttp

func LoadIdenPubOffChainWriteHttp(storage db.Storage) (*IdenPubOffChainWriteHttp, error)

LoadIdenPubOffChainWriteHttp returns a new IdenPubOffChainWriteHttp

func NewIdenPubOffChainWriteHttp

func NewIdenPubOffChainWriteHttp(cfg *Config, storage db.Storage) (*IdenPubOffChainWriteHttp, error)

NewIdenPubOffChainWriteHttp returns a new IdenPubOffChainWriteHttp

func (*IdenPubOffChainWriteHttp) GetPublicData

func (i *IdenPubOffChainWriteHttp) GetPublicData(queryIdenState *merkletree.Hash) (*idenpuboffchain.PublicDataBlobs, error)

GetPublicData returns the identity off chain public data corresponding to the queryIdenState. If the queryIdenState is nil, the last identity off chain public data is returned.

func (*IdenPubOffChainWriteHttp) Publish

func (i *IdenPubOffChainWriteHttp) Publish(id *core.ID, publicData *idenpuboffchain.PublicData) error

Publish publishes the RootsTree and RevocationsTree to the configured way of publishing

func (*IdenPubOffChainWriteHttp) Url

Source Files

Jump to

Keyboard shortcuts

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