Documentation ¶
Index ¶
- Constants
- Variables
- func ErrInvalidString(valuestr string) sdk.Error
- func GetParamKey(keystr string) string
- func GetParamSpaceFromKey(keystr string) string
- func InitGenesisParameter(p Parameter, ctx sdk.Context, genesisData interface{})
- func RegisterGovParamMapping(gps ...GovParameter)
- func RegisterParamSet(ps ...ParamSet)
- func SetParamReadWriter(paramSpace Subspace, ps ...Parameter)
- type GovArrayParameter
- type GovParameter
- type Keeper
- type KeyValuePairs
- type ParamSet
- type Parameter
- type ReadOnlySubspace
- type SignalParameter
- type Subspace
- type TypeTable
Constants ¶
View Source
const ( DefaultCodespace sdk.CodespaceType = "params" // CodeInvalidString sdk.CodeType = 0 //gov CodeInvalidMinDeposit sdk.CodeType = 100 CodeInvalidMinDepositDenom sdk.CodeType = 101 CodeInvalidMinDepositAmount sdk.CodeType = 102 CodeInvalidDepositPeriod sdk.CodeType = 103 CodeInvalidVotingPeriod sdk.CodeType = 104 CodeInvalidVotingProcedure sdk.CodeType = 105 CodeInvalidThreshold sdk.CodeType = 106 CodeInvalidParticipation sdk.CodeType = 107 CodeInvalidVeto sdk.CodeType = 108 CodeInvalidGovernancePenalty sdk.CodeType = 109 CodeInvalidTallyingProcedure sdk.CodeType = 110 CodeInvalidKey sdk.CodeType = 111 CodeInvalidModule sdk.CodeType = 112 CodeInvalidQueryParams sdk.CodeType = 113 CodeInvalidMaxProposalNum sdk.CodeType = 114 CodeInvalidSystemHaltPeriod sdk.CodeType = 115 //service CodeInvalidMaxRequestTimeout sdk.CodeType = 200 CodeInvalidMinDepositMultiple sdk.CodeType = 201 CodeInvalidServiceFeeTax sdk.CodeType = 202 CodeInvalidSlashFraction sdk.CodeType = 203 CodeInvalidArbitrationTimeLimit sdk.CodeType = 204 CodeComplaintRetrospect sdk.CodeType = 205 //upgrade CodeInvalidUpgradeParams sdk.CodeType = 300 //mint CodeInvalidMintInflation sdk.CodeType = 400 //stake CodeInvalidUnbondingTime sdk.CodeType = 500 CodeInvalidMaxValidators sdk.CodeType = 501 CodeInvalidBondDenom sdk.CodeType = 502 //auth CodeInvalidGasPriceThreshold sdk.CodeType = 600 //distribution CodeInvalidCommunityTax sdk.CodeType = 700 CodeInvalidBaseProposerReward sdk.CodeType = 701 CodeInvalidBonusProposerReward sdk.CodeType = 702 //slash CodeInvalidSlashParams sdk.CodeType = 800 )
View Source
const ( SignalParamspace = "Sig" GovParamspace = "Gov" )
Variables ¶
View Source
var ParamMapping = make(map[string]GovParameter)
View Source
var ParamSetMapping = make(map[string]ParamSet)
Functions ¶
func ErrInvalidString ¶ added in v0.10.0
func GetParamKey ¶ added in v0.10.0
func GetParamSpaceFromKey ¶ added in v0.10.0
func InitGenesisParameter ¶
func RegisterGovParamMapping ¶
func RegisterGovParamMapping(gps ...GovParameter)
func RegisterParamSet ¶ added in v0.10.0
func RegisterParamSet(ps ...ParamSet)
func SetParamReadWriter ¶
Types ¶
type GovArrayParameter ¶
type GovParameter ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
Keeper of the global paramstore
func NewKeeper ¶
func NewKeeper(cdc *codec.Codec, key *sdk.KVStoreKey, tkey *sdk.TransientStoreKey) (k Keeper)
NewKeeper constructs a params keeper
func (Keeper) GetSubspace ¶
Get existing substore from keeper
type ReadOnlySubspace ¶
type ReadOnlySubspace = subspace.ReadOnlySubspace
re-export types from subspace
type SignalParameter ¶
type SignalParameter interface { Parameter }
Click to show internal directories.
Click to hide internal directories.