mapper

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2019 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MapperName = "qsc"
	Key        = "qsc/%s"
	RootCAKey  = "rootca"
)
View Source
const (
	QSC  = "qsc"
	Qsc  = "qsc"
	Qscs = "qscs"
)

Variables

This section is empty.

Functions

func BuildQSCKey

func BuildQSCKey(qscName string) []byte

func BuildQSCKeyPrefix

func BuildQSCKeyPrefix() []byte

func BuildQueryQSCPath added in v0.0.8

func BuildQueryQSCPath(qscName string) string

func BuildQueryQSCsPath added in v0.0.8

func BuildQueryQSCsPath() string

func QSCsInvariant added in v0.0.7

func QSCsInvariant(module string) qtypes.Invariant

func Query added in v0.0.8

func Query(ctx context.Context, route []string, req abci.RequestQuery) (res []byte, err btypes.Error)

Types

type Mapper

type Mapper struct {
	*mapper.BaseMapper
}

func GetMapper

func GetMapper(ctx context.Context) *Mapper

func NewMapper

func NewMapper() *Mapper

func (*Mapper) Copy

func (mapper *Mapper) Copy() mapper.IMapper

func (*Mapper) Exists

func (mapper *Mapper) Exists(qscName string) bool

是否存在代币信息

func (*Mapper) GetQSCs

func (mapper *Mapper) GetQSCs() []types.QSCInfo

获取所有代币

func (*Mapper) GetQsc

func (mapper *Mapper) GetQsc(qscName string) (info types.QSCInfo, exists bool)

根据代币名称获取代币信息

func (*Mapper) GetRootCAPubkey added in v0.0.8

func (mapper *Mapper) GetRootCAPubkey() crypto.PubKey

获取 kepler qsc 根证书公钥

func (*Mapper) SaveQsc

func (mapper *Mapper) SaveQsc(qscInfo *types.QSCInfo)

保存代币信息

func (*Mapper) SetRootCAPubkey added in v0.0.8

func (mapper *Mapper) SetRootCAPubkey(pubKey crypto.PubKey)

保存 kepler qsc 根证书公钥

Jump to

Keyboard shortcuts

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