io

package
v0.0.3-rc-1 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Crypto

type Crypto interface {
	EcdsaGenerate(keyTypeId []byte, seed []byte) []byte
	EcdsaRecoverCompressed(signature []byte, msg []byte) []byte

	Ed25519Generate(keyTypeId []byte, seed []byte) []byte
	Ed25519Verify(signature []byte, message []byte, pubKey []byte) bool

	Sr25519Generate(keyTypeId []byte, seed []byte) []byte
	Sr25519Verify(signature []byte, message []byte, pubKey []byte) bool
}

func NewCrypto

func NewCrypto() Crypto

type Hashing

type Hashing interface {
	Blake128(value []byte) []byte
	Blake256(value []byte) []byte

	Twox128(value []byte) []byte
	Twox64(value []byte) []byte
}

func NewHashing

func NewHashing() Hashing

type Misc

type Misc interface {
	PrintHex([]byte)
	PrintUtf8([]byte)
	RuntimeVersion([]byte) []byte
}

func NewMisc

func NewMisc() Misc

type Offchain

type Offchain interface {
	SubmitTransaction(value []byte) []byte
}

func NewOffchain

func NewOffchain() Offchain

type Storage

type Storage interface {
	Append(key []byte, value []byte)
	Clear(key []byte)
	ClearPrefix(key []byte, limit []byte)
	Exists(key []byte) bool
	Get(key []byte) (sc.Option[sc.Sequence[sc.U8]], error)
	NextKey(key []byte) (sc.Option[sc.Sequence[sc.U8]], error)
	Read(key []byte, valueOut []byte, offset int32) (sc.Option[sc.U32], error)
	Root(version int32) []byte
	Set(key []byte, value []byte)
}

func NewStorage

func NewStorage() Storage

type TransactionBroker

type TransactionBroker interface {
	Start()
	Commit()
	Rollback()
}

func NewTransactionBroker

func NewTransactionBroker() TransactionBroker

type Trie

type Trie interface {
	Blake2256OrderedRoot(key []byte, version int32) []byte
}

func NewTrie

func NewTrie() Trie

Jump to

Keyboard shortcuts

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