Documentation ¶
Index ¶
- Constants
- Variables
- func GetAccAddress(attrs []sdk.Attribute, key string) (sdk.AccAddress, error)
- func GetString(attrs []sdk.Attribute, key string) (string, error)
- func GetUint64(attrs []sdk.Attribute, key string) (uint64, error)
- func MustAccAddressFromBech32(address string) sdk.AccAddress
- type BaseModuleEvent
- type EncodingConfig
- type Event
- type ModuleEvent
Constants ¶
const ( BondDenom = "uakt" Bech32PrefixAccAddr = "akash" Bech32PrefixAccPub = "akashpub" Bech32PrefixValAddr = "akashvaloper" Bech32PrefixValPub = "akashvaloperpub" Bech32PrefixConsAddr = "akashvalcons" Bech32PrefixConsPub = "akashvalconspub" )
const (
// EventTypeMessage defines the Akash message string
EventTypeMessage = akashEventMessageV1
)
Variables ¶
var ( // ErrNotFound is the error with message "Not found" ErrNotFound = errors.New("Not found") // ErrUnknownType is the error with message "Unknown type" ErrUnknownType = errors.New("Unknown type") // ErrUnknownModule is the error with message "Unknown module" ErrUnknownModule = errors.New("Unknown module") // ErrUnknownAction is the error with message "Unknown action" ErrUnknownAction = errors.New("Unknown action") // ErrParsingBlockID indicates one of the uint parsers failed to convert a value. ErrParsingBlockID = errors.New("error parsing block id values") // ErrInvalidParseBlockIDInput indicates the splitting of block path failed. ErrInvalidParseBlockIDInput = errors.New("error parsing block id input string") )
Functions ¶
func GetAccAddress ¶
GetAccAddress take sdk attributes, key and returns account address. Returns error incase of failure.
func GetString ¶
GetString take sdk attributes, key and returns key value. Returns error incase of failure.
func GetUint64 ¶
GetUint64 take sdk attributes, key and returns uint64 value. Returns error incase of failure.
func MustAccAddressFromBech32 ¶
func MustAccAddressFromBech32(address string) sdk.AccAddress
MustAccAddressFromBech32 creates an AccAddress from a Bech32 string. It panics if there is an error.
Types ¶
type BaseModuleEvent ¶
type EncodingConfig ¶
type EncodingConfig struct { InterfaceRegistry types.InterfaceRegistry Marshaler codec.Codec TxConfig client.TxConfig Amino *codec.LegacyAmino }
EncodingConfig specifies the concrete encoding types to use for a given app. This is provided for compatibility between protobuf and amino implementations.
func MakeEncodingConfig ¶
func MakeEncodingConfig() EncodingConfig
MakeEncodingConfig creates an EncodingConfig for a proto based test configuration.
type Event ¶
Event stores type, module, action and attributes list of sdk
func ParseEvent ¶
func ParseEvent(sev sdk.StringEvent) (Event, error)
ParseEvent parses string to event