helpers

package
v1.4.0-develop.1 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Codec    codec.Codec
	Registry types.InterfaceRegistry
)

Functions

func GenerateFeeGranter

func GenerateFeeGranter(granter string, feeParams []string) []string

func GenerateFees

func GenerateFees(amount string) []string

func GetBurntPortion

func GetBurntPortion(tax sdk.Coin, burnFactor sdk.Dec) sdk.Coin

func GetRewardPortion

func GetRewardPortion(tax sdk.Coin, burnt sdk.Coin) sdk.Coin

func MustWriteTmpFile

func MustWriteTmpFile(tmpDir string, content []byte) string

func TrimExtraLineOffset

func TrimExtraLineOffset(input string, offset int) string

func TrimImportedStdout

func TrimImportedStdout(output string) string

func WriteTmpFile

func WriteTmpFile(tmpDir string, content []byte) (string, error)

Types

type DeepCopyCreateDid

type DeepCopyCreateDid struct {
	TDeepCopy
}

DeepCopyCreateDid is a decorator for deep copy of type MsgCreateDidPayload.

func (*DeepCopyCreateDid) DeepCopy

type DeepCopyCreateResource

type DeepCopyCreateResource struct {
	TDeepCopy
}

DeepCopyCreateResource is a decorator for deep copy of type MsgCreateResource.

func (*DeepCopyCreateResource) DeepCopy

type DeepCopyDIDDocument added in v1.2.0

type DeepCopyDIDDocument struct {
	TDeepCopy
}

func (*DeepCopyDIDDocument) DeepCopy added in v1.2.0

type DeepCopyUpdateDid

type DeepCopyUpdateDid struct {
	TDeepCopy
}

DeepCopyUpdateDid is a decorator for deep copy of type MsgUpdateDidPayload.

func (*DeepCopyUpdateDid) DeepCopy

type HumanReadableEvent

type HumanReadableEvent struct {
	Type       string                        `json:"type"`
	Attributes []HumanReadableEventAttribute `json:"attributes"`
}

func ReadableEvents

func ReadableEvents(events []types.Event) []HumanReadableEvent

type HumanReadableEventAttribute

type HumanReadableEventAttribute struct {
	Key   string `json:"key"`
	Value string `json:"value"`
	Index bool   `json:"index,omitempty"`
}

type IDeepCopy

type IDeepCopy interface {
	DeepCopy(src interface{}) interface{}
}

IDeepCopy is an interface for deep copy in the decorator pattern.

type TDeepCopy

type TDeepCopy struct{}

TDeepCopy is a decorator for deep copy.

func (*TDeepCopy) DeepCopy

func (d *TDeepCopy) DeepCopy(src interface{}) interface{}

Jump to

Keyboard shortcuts

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