Documentation ¶
Index ¶
- Constants
- Variables
- func BlockGasLimit(ctx sdk.Context) uint64
- func IsEmptyHash(hash string) bool
- func IsZeroAddress(address string) bool
- func KeyringServiceName() string
- func NewCoin(amount sdkmath.Int) sdk.Coin
- func NewCoinInt64(amount int64) sdk.Coin
- func NewDecCoin(amount sdkmath.Int) sdk.DecCoin
- func NewInfiniteGasMeterWithLimit(limit sdk.Gas) sdk.GasMeter
- func ProtoAccount() authtypes.AccountI
- func RegisterInterfaces(registry codectypes.InterfaceRegistry)
- func SafeInt64(value uint64) (int64, error)
- func SdsPubKeyFromBech32(pubkeyStr string) (cryptotypes.PubKey, error)
- func SdsPubKeyToBech32(pubkey cryptotypes.PubKey) (string, error)
- func ValidateHexAddress(address string) error
- type Coins
- func (*Coins) Descriptor() ([]byte, []int)
- func (m *Coins) GetValue() github_com_cosmos_cosmos_sdk_types.Coins
- func (m *Coins) Marshal() (dAtA []byte, err error)
- func (m *Coins) MarshalTo(dAtA []byte) (int, error)
- func (m *Coins) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Coins) ProtoMessage()
- func (m *Coins) Reset()
- func (m *Coins) Size() (n int)
- func (m *Coins) String() string
- func (m *Coins) Unmarshal(dAtA []byte) error
- func (m *Coins) XXX_DiscardUnknown()
- func (m *Coins) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Coins) XXX_Merge(src proto.Message)
- func (m *Coins) XXX_Size() int
- func (m *Coins) XXX_Unmarshal(b []byte) error
- type Config
- func (config *Config) GetAddressVerifier() func([]byte) error
- func (config *Config) GetBech32AccountAddrPrefix() string
- func (config *Config) GetBech32AccountPubPrefix() string
- func (config *Config) GetBech32ConsensusAddrPrefix() string
- func (config *Config) GetBech32ConsensusPubPrefix() string
- func (config *Config) GetBech32SdsNodeP2PAddrPrefix() string
- func (config *Config) GetBech32SdsNodeP2PPubPrefix() string
- func (config *Config) GetBech32ValidatorAddrPrefix() string
- func (config *Config) GetBech32ValidatorPubPrefix() string
- func (config *Config) GetCoinType() uint32
- func (config *Config) GetFullBIP44Path() string
- func (config *Config) GetPurpose() uint32
- func (config *Config) GetTxEncoder() sdk.TxEncoder
- func (config *Config) Seal() *Config
- func (config *Config) SetAddressVerifier(addressVerifier func([]byte) error)
- func (config *Config) SetBech32PrefixForAccount(addressPrefix, pubKeyPrefix string)
- func (config *Config) SetBech32PrefixForConsensusNode(addressPrefix, pubKeyPrefix string)
- func (config *Config) SetBech32PrefixForSdsNodeP2P(pubKeyPrefix, p2pAddrPrifx string)
- func (config *Config) SetBech32PrefixForValidator(addressPrefix, pubKeyPrefix string)
- func (config *Config) SetCoinType(coinType uint32)
- func (config *Config) SetTxEncoder(encoder sdk.TxEncoder)
- type Dec
- func (*Dec) Descriptor() ([]byte, []int)
- func (m *Dec) Marshal() (dAtA []byte, err error)
- func (m *Dec) MarshalTo(dAtA []byte) (int, error)
- func (m *Dec) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Dec) ProtoMessage()
- func (m *Dec) Reset()
- func (m *Dec) Size() (n int)
- func (m *Dec) String() string
- func (m *Dec) Unmarshal(dAtA []byte) error
- func (m *Dec) XXX_DiscardUnknown()
- func (m *Dec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Dec) XXX_Merge(src proto.Message)
- func (m *Dec) XXX_Size() int
- func (m *Dec) XXX_Unmarshal(b []byte) error
- type ErrorGasOverflow
- type ErrorNegativeGasConsumed
- type EthAccount
- func (*EthAccount) Descriptor() ([]byte, []int)
- func (acc EthAccount) EthAddress() common.Address
- func (acc EthAccount) GetCodeHash() common.Hash
- func (m *EthAccount) Marshal() (dAtA []byte, err error)
- func (m *EthAccount) MarshalTo(dAtA []byte) (int, error)
- func (m *EthAccount) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*EthAccount) ProtoMessage()
- func (m *EthAccount) Reset()
- func (acc *EthAccount) SetCodeHash(codeHash common.Hash) error
- func (m *EthAccount) Size() (n int)
- func (acc EthAccount) Type() int8
- func (m *EthAccount) Unmarshal(dAtA []byte) error
- func (m *EthAccount) XXX_DiscardUnknown()
- func (m *EthAccount) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *EthAccount) XXX_Merge(src proto.Message)
- func (m *EthAccount) XXX_Size() int
- func (m *EthAccount) XXX_Unmarshal(b []byte) error
- type EthAccountI
- type HDPathIterator
- type Int
- func (*Int) Descriptor() ([]byte, []int)
- func (m *Int) Marshal() (dAtA []byte, err error)
- func (m *Int) MarshalTo(dAtA []byte) (int, error)
- func (m *Int) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Int) ProtoMessage()
- func (m *Int) Reset()
- func (m *Int) Size() (n int)
- func (m *Int) String() string
- func (m *Int) Unmarshal(dAtA []byte) error
- func (m *Int) XXX_DiscardUnknown()
- func (m *Int) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Int) XXX_Merge(src proto.Message)
- func (m *Int) XXX_Size() int
- func (m *Int) XXX_Unmarshal(b []byte) error
- type SdsAddress
- func (aa SdsAddress) Bytes() []byte
- func (aa SdsAddress) Empty() bool
- func (aa SdsAddress) Equals(aa2 sdk.Address) bool
- func (aa SdsAddress) Format(s fmt.State, verb rune)
- func (aa SdsAddress) Marshal() ([]byte, error)
- func (aa SdsAddress) MarshalJSON() ([]byte, error)
- func (aa SdsAddress) MarshalYAML() (interface{}, error)
- func (aa SdsAddress) String() string
- func (aa *SdsAddress) Unmarshal(data []byte) error
- func (aa *SdsAddress) UnmarshalJSON(data []byte) error
- func (aa *SdsAddress) UnmarshalYAML(data []byte) error
- type SdsAddresses
- func (*SdsAddresses) Descriptor() ([]byte, []int)
- func (m *SdsAddresses) GetAddresses() []string
- func (m *SdsAddresses) Marshal() (dAtA []byte, err error)
- func (m *SdsAddresses) MarshalTo(dAtA []byte) (int, error)
- func (m *SdsAddresses) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SdsAddresses) ProtoMessage()
- func (m *SdsAddresses) Reset()
- func (m *SdsAddresses) Size() (n int)
- func (this *SdsAddresses) String() string
- func (m *SdsAddresses) Unmarshal(dAtA []byte) error
- func (m *SdsAddresses) XXX_DiscardUnknown()
- func (m *SdsAddresses) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SdsAddresses) XXX_Merge(src proto.Message)
- func (m *SdsAddresses) XXX_Size() int
- func (m *SdsAddresses) XXX_Unmarshal(b []byte) error
- type Web3Msg
- type Web3MsgType
Constants ¶
const ( // AccountTypeEOA defines the type for externally owned accounts (EOAs) AccountTypeEOA = int8(iota + 1) // AccountTypeContract defines the type for contract accounts AccountTypeContract )
const ( StratosBech32Prefix = "st" // PrefixSds is the prefix for sds keys PrefixSds = "sds" // AccountAddressPrefix defines the Bech32 prefix of an account's address (st) AccountAddressPrefix = StratosBech32Prefix // AccountPubKeyPrefix defines the Bech32 prefix of an account's public key (stpub) AccountPubKeyPrefix = StratosBech32Prefix + sdk.PrefixPublic // ValidatorAddressPrefix defines the Bech32 prefix of a validator's operator address (stvaloper) ValidatorAddressPrefix = StratosBech32Prefix + sdk.PrefixValidator + sdk.PrefixOperator // ValidatorPubKeyPrefix defines the Bech32 prefix of a validator's operator public key (stvaloperpub) ValidatorPubKeyPrefix = StratosBech32Prefix + sdk.PrefixValidator + sdk.PrefixOperator + sdk.PrefixPublic // ConsNodeAddressPrefix defines the Bech32 prefix of a consensus node address (stvalcons) ConsNodeAddressPrefix = StratosBech32Prefix + sdk.PrefixValidator + sdk.PrefixConsensus // ConsNodePubKeyPrefix defines the Bech32 prefix of a consensus node public key (stvalconspub) ConsNodePubKeyPrefix = StratosBech32Prefix + sdk.PrefixValidator + sdk.PrefixConsensus + sdk.PrefixPublic // SdsNodeP2PPubkeyPrefix defines the Bech32 prefix of an sds account's public key (stsdspub) SdsNodeP2PPubkeyPrefix = StratosBech32Prefix + PrefixSds + sdk.PrefixPublic // SdsNodeP2PAddressPrefix defines the Bech32 prefix of an sds account's address (stsds) SdsNodeP2PAddressPrefix = StratosBech32Prefix + PrefixSds )
Bech32 conversion constants
const ( CoinType = 606 // Stos defines the denomination displayed to users in client applications. Stos = "stos" Gwei = "gwei" Wei = "wei" Utros = "utros" // reward denom // WeiDenomUnit defines the base denomination unit for stos. // 1 stos = 1x10^{WeiDenomUnit} wei WeiDenomUnit = 18 GweiDenomUnit = 9 StosToWei = 1e18 // 1 Stos = 1e18 wei StosToGwei = 1e9 // 1 Stos = 1e9 Gwei GweiToWei = 1e9 // 1 Gwei = 1e9 wei // DefaultGasPrice is default gas price for evm transactions DefaultGasPrice = 20 )
const DefaultKeyringServiceName = "stratos"
DefaultKeyringServiceName defines a default service name for the keyring.
const (
// ProtocolVersion is the latest supported version of the eth protocol.
ProtocolVersion = eth65
)
Constants to match up protocol versions and messages
const (
// RootCodespace is the codespace for all errors defined in this package
RootCodespace = "stratos"
)
Variables ¶
var ( ErrInvalidLengthAccount = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowAccount = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupAccount = fmt.Errorf("proto: unexpected end of group") )
var ( // ErrInvalidValue returns an error resulting from an invalid value. ErrInvalidValue = errors.Register(RootCodespace, 2, "invalid value") // ErrInvalidChainID returns an error resulting from an invalid chain ID. ErrInvalidChainID = errors.Register(RootCodespace, 3, "invalid chain ID") // ErrMarshalBigInt returns an error resulting from marshaling a big.Int to a string. ErrMarshalBigInt = errors.Register(RootCodespace, 5, "cannot marshal big.Int to string") // ErrUnmarshalBigInt returns an error resulting from unmarshaling a big.Int from a string. ErrUnmarshalBigInt = errors.Register(RootCodespace, 6, "cannot unmarshal big.Int from string") )
Functions ¶
func BlockGasLimit ¶ added in v0.8.0
BlockGasLimit returns the max gas (limit) defined in the block gas meter. If the meter is not set, it returns the max gas from the application consensus params. NOTE: see https://github.com/cosmos/cosmos-sdk/issues/9514 for full reference
func IsEmptyHash ¶ added in v0.8.0
IsEmptyHash returns true if the hash corresponds to an empty ethereum hex hash.
func IsZeroAddress ¶ added in v0.8.0
IsZeroAddress returns true if the address corresponds to an empty ethereum hex address.
func KeyringServiceName ¶
func KeyringServiceName() string
func NewCoinInt64 ¶ added in v0.9.0
func NewInfiniteGasMeterWithLimit ¶ added in v0.8.0
NewInfiniteGasMeterWithLimit returns a reference to a new infiniteGasMeter.
func ProtoAccount ¶ added in v0.8.0
ProtoAccount defines the prototype function for BaseAccount used for an accountKeeper.
func RegisterInterfaces ¶ added in v0.8.0
func RegisterInterfaces(registry codectypes.InterfaceRegistry)
RegisterInterfaces registers the tendermint concrete client-related implementations and interfaces.
func SafeInt64 ¶ added in v0.8.0
SafeInt64 checks for overflows while casting an uint64 to int64 value.
func SdsPubKeyFromBech32 ¶ added in v0.8.0
func SdsPubKeyFromBech32(pubkeyStr string) (cryptotypes.PubKey, error)
SdsPubKeyFromBech32 returns an ed25519 SdsPublicKey from a Bech32 string.
func SdsPubKeyToBech32 ¶ added in v0.8.0
func SdsPubKeyToBech32(pubkey cryptotypes.PubKey) (string, error)
SdsPubKeyToBech32 convert a SdsPublicKey to a Bech32 string.
func ValidateHexAddress ¶ added in v0.10.0
ValidateHexAddress returns an error if the provided string is either not a hex formatted string address
Types ¶
type Coins ¶ added in v0.10.0
type Coins struct {
Value github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,1,rep,name=Value,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"Value"`
}
func (*Coins) Descriptor ¶ added in v0.10.0
func (*Coins) GetValue ¶ added in v0.10.0
func (m *Coins) GetValue() github_com_cosmos_cosmos_sdk_types.Coins
func (*Coins) MarshalToSizedBuffer ¶ added in v0.10.0
func (*Coins) ProtoMessage ¶ added in v0.10.0
func (*Coins) ProtoMessage()
func (*Coins) XXX_DiscardUnknown ¶ added in v0.10.0
func (m *Coins) XXX_DiscardUnknown()
func (*Coins) XXX_Marshal ¶ added in v0.10.0
func (*Coins) XXX_Unmarshal ¶ added in v0.10.0
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
Config is the structure that holds the SDK configuration parameters. This could be used to initialize certain configuration parameters for the SDK.
func GetSealedConfig ¶
GetSealedConfig returns the config instance for the SDK if/once it is sealed.
func (*Config) GetAddressVerifier ¶
GetAddressVerifier returns the function to verify that addresses have the correct format
func (*Config) GetBech32AccountAddrPrefix ¶
GetBech32AccountAddrPrefix returns the Bech32 prefix for account address
func (*Config) GetBech32AccountPubPrefix ¶
GetBech32AccountPubPrefix returns the Bech32 prefix for account public key
func (*Config) GetBech32ConsensusAddrPrefix ¶
GetBech32ConsensusAddrPrefix returns the Bech32 prefix for consensus node address
func (*Config) GetBech32ConsensusPubPrefix ¶
GetBech32ConsensusPubPrefix returns the Bech32 prefix for consensus node public key
func (*Config) GetBech32SdsNodeP2PAddrPrefix ¶ added in v0.7.0
func (*Config) GetBech32SdsNodeP2PPubPrefix ¶
func (*Config) GetBech32ValidatorAddrPrefix ¶
GetBech32ValidatorAddrPrefix returns the Bech32 prefix for validator address
func (*Config) GetBech32ValidatorPubPrefix ¶
GetBech32ValidatorPubPrefix returns the Bech32 prefix for validator public key
func (*Config) GetCoinType ¶
GetCoinType returns the BIP-0044 CoinType code on the config.
func (*Config) GetFullBIP44Path ¶ added in v0.8.0
GetFullBIP44Path returns the BIP44Prefix.
func (*Config) GetPurpose ¶ added in v0.8.0
GetPurpose returns the BIP-0044 Purpose code on the config.
func (*Config) GetTxEncoder ¶
GetTxEncoder return function to encode transactions
func (*Config) Seal ¶
Seal seals the config such that the config state could not be modified further
func (*Config) SetAddressVerifier ¶
SetAddressVerifier builds the Config with the provided function for verifying that addresses have the correct format
func (*Config) SetBech32PrefixForAccount ¶
SetBech32PrefixForAccount builds the Config with Bech32 addressPrefix and publKeyPrefix for accounts and returns the config instance
func (*Config) SetBech32PrefixForConsensusNode ¶
SetBech32PrefixForConsensusNode builds the Config with Bech32 addressPrefix and publKeyPrefix for consensus nodes and returns the config instance
func (*Config) SetBech32PrefixForSdsNodeP2P ¶
func (*Config) SetBech32PrefixForValidator ¶
SetBech32PrefixForValidator builds the Config with Bech32 addressPrefix and publKeyPrefix for validators
and returns the config instance
func (*Config) SetCoinType ¶
SetCoinType Set the BIP-0044 CoinType code on the config
func (*Config) SetTxEncoder ¶
SetTxEncoder builds the Config with TxEncoder used to marshal StdTx to bytes
type Dec ¶ added in v0.10.0
type Dec struct {
Value *github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,1,opt,name=Value,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"Value,omitempty"`
}
func (*Dec) Descriptor ¶ added in v0.10.0
func (*Dec) MarshalToSizedBuffer ¶ added in v0.10.0
func (*Dec) ProtoMessage ¶ added in v0.10.0
func (*Dec) ProtoMessage()
func (*Dec) XXX_DiscardUnknown ¶ added in v0.10.0
func (m *Dec) XXX_DiscardUnknown()
func (*Dec) XXX_Marshal ¶ added in v0.10.0
func (*Dec) XXX_Unmarshal ¶ added in v0.10.0
type ErrorGasOverflow ¶ added in v0.8.0
type ErrorGasOverflow struct {
Descriptor string
}
ErrorGasOverflow defines an error thrown when an action results gas consumption unsigned integer overflow.
type ErrorNegativeGasConsumed ¶ added in v0.8.0
type ErrorNegativeGasConsumed struct {
Descriptor string
}
ErrorNegativeGasConsumed defines an error thrown when the amount of gas refunded results in a negative gas consumed amount. Copied from cosmos-sdk
type EthAccount ¶ added in v0.8.0
type EthAccount struct { *types.BaseAccount `` /* 136-byte string literal not displayed */ CodeHash string `protobuf:"bytes,2,opt,name=code_hash,json=codeHash,proto3" json:"code_hash,omitempty" yaml:"code_hash"` }
EthAccount implements the authtypes.AccountI interface and embeds an authtypes.BaseAccount type. It is compatible with the auth AccountKeeper.
func (*EthAccount) Descriptor ¶ added in v0.8.0
func (*EthAccount) Descriptor() ([]byte, []int)
func (EthAccount) EthAddress ¶ added in v0.8.0
func (acc EthAccount) EthAddress() common.Address
EthAddress returns the account address ethereum format.
func (EthAccount) GetCodeHash ¶ added in v0.8.0
func (acc EthAccount) GetCodeHash() common.Hash
GetCodeHash returns the account code hash in byte format
func (*EthAccount) Marshal ¶ added in v0.8.0
func (m *EthAccount) Marshal() (dAtA []byte, err error)
func (*EthAccount) MarshalTo ¶ added in v0.8.0
func (m *EthAccount) MarshalTo(dAtA []byte) (int, error)
func (*EthAccount) MarshalToSizedBuffer ¶ added in v0.8.0
func (m *EthAccount) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*EthAccount) ProtoMessage ¶ added in v0.8.0
func (*EthAccount) ProtoMessage()
func (*EthAccount) Reset ¶ added in v0.8.0
func (m *EthAccount) Reset()
func (*EthAccount) SetCodeHash ¶ added in v0.8.0
func (acc *EthAccount) SetCodeHash(codeHash common.Hash) error
SetCodeHash sets the account code hash to the EthAccount fields
func (*EthAccount) Size ¶ added in v0.8.0
func (m *EthAccount) Size() (n int)
func (EthAccount) Type ¶ added in v0.8.0
func (acc EthAccount) Type() int8
Type returns the type of Ethereum Account (EOA or Contract)
func (*EthAccount) Unmarshal ¶ added in v0.8.0
func (m *EthAccount) Unmarshal(dAtA []byte) error
func (*EthAccount) XXX_DiscardUnknown ¶ added in v0.8.0
func (m *EthAccount) XXX_DiscardUnknown()
func (*EthAccount) XXX_Marshal ¶ added in v0.8.0
func (m *EthAccount) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*EthAccount) XXX_Merge ¶ added in v0.8.0
func (m *EthAccount) XXX_Merge(src proto.Message)
func (*EthAccount) XXX_Size ¶ added in v0.8.0
func (m *EthAccount) XXX_Size() int
func (*EthAccount) XXX_Unmarshal ¶ added in v0.8.0
func (m *EthAccount) XXX_Unmarshal(b []byte) error
type EthAccountI ¶ added in v0.8.0
type EthAccountI interface { authtypes.AccountI // EthAddress returns the ethereum Address representation of the AccAddress EthAddress() common.Address // GetCodeHash is the keccak256 hash of the contract code (if any) GetCodeHash() common.Hash // SetCodeHash sets the code hash to the account fields SetCodeHash(code common.Hash) error // Type returns the type of Ethereum Account (EOA or Contract) Type() int8 }
EthAccountI represents the interface of an EVM compatible account
type HDPathIterator ¶ added in v0.8.0
type HDPathIterator func() ethaccounts.DerivationPath
func NewHDPathIterator ¶ added in v0.8.0
func NewHDPathIterator(basePath string, ledgerIter bool) (HDPathIterator, error)
NewHDPathIterator receives a base path as a string and a boolean for the desired iterator type and returns a function that iterates over the base HD path, returning the string.
type Int ¶ added in v0.10.0
type Int struct {
Value *github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,1,opt,name=Value,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"Value,omitempty"`
}
func (*Int) Descriptor ¶ added in v0.10.0
func (*Int) MarshalToSizedBuffer ¶ added in v0.10.0
func (*Int) ProtoMessage ¶ added in v0.10.0
func (*Int) ProtoMessage()
func (*Int) XXX_DiscardUnknown ¶ added in v0.10.0
func (m *Int) XXX_DiscardUnknown()
func (*Int) XXX_Marshal ¶ added in v0.10.0
func (*Int) XXX_Unmarshal ¶ added in v0.10.0
type SdsAddress ¶ added in v0.7.0
type SdsAddress []byte
func SdsAddressFromBech32 ¶ added in v0.7.0
func SdsAddressFromBech32(address string) (addr SdsAddress, err error)
SdsAddressFromBech32 creates an SdsAddress from a Bech32 string.
func SdsAddressFromHex ¶ added in v0.8.0
func SdsAddressFromHex(address string) (addr SdsAddress, err error)
SdsAddressFromHex creates an SdsAddress from a hex string.
func (SdsAddress) Bytes ¶ added in v0.7.0
func (aa SdsAddress) Bytes() []byte
Bytes returns the raw address bytes.
func (SdsAddress) Empty ¶ added in v0.7.0
func (aa SdsAddress) Empty() bool
Empty Returns boolean for whether a SdsAddress is empty
func (SdsAddress) Equals ¶ added in v0.7.0
func (aa SdsAddress) Equals(aa2 sdk.Address) bool
Equals Returns boolean for whether two SdsAddress are Equal
func (SdsAddress) Format ¶ added in v0.7.0
func (aa SdsAddress) Format(s fmt.State, verb rune)
Format implements the fmt.Formatter interface.
func (SdsAddress) Marshal ¶ added in v0.7.0
func (aa SdsAddress) Marshal() ([]byte, error)
Marshal returns the raw address bytes. It is needed for protobuf compatibility.
func (SdsAddress) MarshalJSON ¶ added in v0.7.0
func (aa SdsAddress) MarshalJSON() ([]byte, error)
MarshalJSON marshals to JSON using Bech32.
func (SdsAddress) MarshalYAML ¶ added in v0.7.0
func (aa SdsAddress) MarshalYAML() (interface{}, error)
MarshalYAML marshals to YAML using Bech32.
func (SdsAddress) String ¶ added in v0.7.0
func (aa SdsAddress) String() string
String implements the Stringer interface.
func (*SdsAddress) Unmarshal ¶ added in v0.7.0
func (aa *SdsAddress) Unmarshal(data []byte) error
Unmarshal sets the address to the given data. It is needed for protobuf compatibility.
func (*SdsAddress) UnmarshalJSON ¶ added in v0.7.0
func (aa *SdsAddress) UnmarshalJSON(data []byte) error
UnmarshalJSON unmarshals from JSON assuming Bech32 encoding.
func (*SdsAddress) UnmarshalYAML ¶ added in v0.7.0
func (aa *SdsAddress) UnmarshalYAML(data []byte) error
UnmarshalYAML unmarshals from JSON assuming Bech32 encoding.
type SdsAddresses ¶ added in v0.10.0
type SdsAddresses struct {
Addresses []string `protobuf:"bytes,1,rep,name=Addresses,proto3" json:"Addresses,omitempty"`
}
ValAddresses defines a repeated set of validator addresses.
func (*SdsAddresses) Descriptor ¶ added in v0.10.0
func (*SdsAddresses) Descriptor() ([]byte, []int)
func (*SdsAddresses) GetAddresses ¶ added in v0.10.0
func (m *SdsAddresses) GetAddresses() []string
func (*SdsAddresses) Marshal ¶ added in v0.10.0
func (m *SdsAddresses) Marshal() (dAtA []byte, err error)
func (*SdsAddresses) MarshalTo ¶ added in v0.10.0
func (m *SdsAddresses) MarshalTo(dAtA []byte) (int, error)
func (*SdsAddresses) MarshalToSizedBuffer ¶ added in v0.10.0
func (m *SdsAddresses) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SdsAddresses) ProtoMessage ¶ added in v0.10.0
func (*SdsAddresses) ProtoMessage()
func (*SdsAddresses) Reset ¶ added in v0.10.0
func (m *SdsAddresses) Reset()
func (*SdsAddresses) Size ¶ added in v0.10.0
func (m *SdsAddresses) Size() (n int)
func (*SdsAddresses) String ¶ added in v0.10.0
func (this *SdsAddresses) String() string
func (*SdsAddresses) Unmarshal ¶ added in v0.10.0
func (m *SdsAddresses) Unmarshal(dAtA []byte) error
func (*SdsAddresses) XXX_DiscardUnknown ¶ added in v0.10.0
func (m *SdsAddresses) XXX_DiscardUnknown()
func (*SdsAddresses) XXX_Marshal ¶ added in v0.10.0
func (m *SdsAddresses) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SdsAddresses) XXX_Merge ¶ added in v0.10.0
func (m *SdsAddresses) XXX_Merge(src proto.Message)
func (*SdsAddresses) XXX_Size ¶ added in v0.10.0
func (m *SdsAddresses) XXX_Size() int
func (*SdsAddresses) XXX_Unmarshal ¶ added in v0.10.0
func (m *SdsAddresses) XXX_Unmarshal(b []byte) error