guardian

package
v1.0.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2021 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 AccountType

type AccountType byte
const (
	Genesis  AccountType = 0x01
	Ordinary AccountType = 0x02
)

func AccountTypeFromString

func AccountTypeFromString(str string) (AccountType, error)

String to AccountType byte, Returns ff if invalid.

func (AccountType) Format

func (bt AccountType) Format(s fmt.State, verb rune)

func (AccountType) MarshalJSON

func (bt AccountType) MarshalJSON() ([]byte, error)

Marshals to JSON using string

func (AccountType) String

func (bt AccountType) String() string

Turns BindingType byte to String

func (*AccountType) UnmarshalJSON

func (bt *AccountType) UnmarshalJSON(data []byte) error

Unmarshals from JSON assuming Bech32 encoding

type GenesisState

type GenesisState struct {
	Profilers []Guardian `json:"profilers"`
	Trustees  []Guardian `json:"trustees"`
}

type Guardian

type Guardian struct {
	Description string         `json:"description"`
	AccountType AccountType    `json:"type"`
	Address     sdk.AccAddress `json:"address"`  // this guardian's address
	AddedBy     sdk.AccAddress `json:"added_by"` // address that initiated the AddGuardian tx
}

Jump to

Keyboard shortcuts

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