Documentation ¶
Index ¶
- Constants
- func HandleAddMsgFeeProposal(ctx sdk.Context, k Keeper, proposal *types.AddMsgFeeProposal, ...) error
- func HandleRemoveMsgFeeProposal(ctx sdk.Context, k Keeper, proposal *types.RemoveMsgFeeProposal, ...) error
- func HandleUpdateMsgFeeProposal(ctx sdk.Context, k Keeper, proposal *types.UpdateMsgFeeProposal, ...) error
- type Handler
- type Keeper
- func (k Keeper) CalculateTxFees(goCtx context.Context, request *types.CalculateTxFeesRequest) (*types.CalculateTxFeesResponse, error)
- func (k Keeper) DeductFees(bankKeeper cosmosauthtypes.BankKeeper, ctx sdk.Context, ...) error
- func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState
- func (k Keeper) GetFeeCollectorName() string
- func (k Keeper) GetFloorGasPrice(ctx sdk.Context) sdk.Coin
- func (k Keeper) GetMsgFee(ctx sdk.Context, msgType string) (*types.MsgFee, error)
- func (k Keeper) GetParams(ctx sdk.Context) (params types.Params)
- func (k Keeper) InitGenesis(ctx sdk.Context, data *types.GenesisState)
- func (k Keeper) IterateMsgFees(ctx sdk.Context, handle func(msgFees types.MsgFee) (stop bool)) error
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) Params(ctx context.Context, request *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) QueryAllMsgFees(c context.Context, req *types.QueryAllMsgFeesRequest) (*types.QueryAllMsgFeesResponse, error)
- func (k Keeper) RemoveMsgFee(ctx sdk.Context, msgType string) error
- func (k Keeper) SetMsgFee(ctx sdk.Context, msgFees types.MsgFee) error
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
Constants ¶
const StoreKey = types.ModuleName
StoreKey is the store key string for authz
Variables ¶
This section is empty.
Functions ¶
func HandleAddMsgFeeProposal ¶
func HandleAddMsgFeeProposal(ctx sdk.Context, k Keeper, proposal *types.AddMsgFeeProposal, registry codectypes.InterfaceRegistry) error
HandleAddMsgFeeProposal handles an Add msg fees governance proposal request
func HandleRemoveMsgFeeProposal ¶
func HandleRemoveMsgFeeProposal(ctx sdk.Context, k Keeper, proposal *types.RemoveMsgFeeProposal, registry codectypes.InterfaceRegistry) error
HandleRemoveMsgFeeProposal handles an Remove of an existing msg fees governance proposal request
func HandleUpdateMsgFeeProposal ¶
func HandleUpdateMsgFeeProposal(ctx sdk.Context, k Keeper, proposal *types.UpdateMsgFeeProposal, registry codectypes.InterfaceRegistry) error
HandleUpdateMsgFeeProposal handles an Update of an existing msg fees governance proposal request
Types ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
Keeper of the Additional fee store
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, key sdk.StoreKey, paramSpace paramtypes.Subspace, feeCollectorName string, defaultFeeDenom string, simulateFunc baseAppSimulateFunc, txDecoder sdk.TxDecoder, ) Keeper
NewKeeper returns a AdditionalFeeKeeper. It handles: CONTRACT: the parameter Subspace must have the param key table already initialized
func (Keeper) CalculateTxFees ¶
func (k Keeper) CalculateTxFees(goCtx context.Context, request *types.CalculateTxFeesRequest) (*types.CalculateTxFeesResponse, error)
func (Keeper) DeductFees ¶
func (k Keeper) DeductFees(bankKeeper cosmosauthtypes.BankKeeper, ctx sdk.Context, acc cosmosauthtypes.AccountI, fees sdk.Coins) error
DeductFees deducts fees from the given account, the only reason it exists is that the cosmos method does not take in the custom fee collector which is a feature desired from msg fees.
func (Keeper) ExportGenesis ¶
func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState
ExportGenesis returns a GenesisState for a given context.
func (Keeper) GetFeeCollectorName ¶
func (Keeper) GetFloorGasPrice ¶
GetFloorGasPrice returns the current minimum gas price in sdk.Coin used in calculations for charging additional fees
func (Keeper) GetMsgFee ¶
GetMsgFee returns a MsgFee for the msg type if it exists nil if it does not
func (Keeper) InitGenesis ¶
func (k Keeper) InitGenesis(ctx sdk.Context, data *types.GenesisState)
InitGenesis new msgfees genesis
func (Keeper) IterateMsgFees ¶
func (k Keeper) IterateMsgFees(ctx sdk.Context, handle func(msgFees types.MsgFee) (stop bool)) error
IterateMsgFees iterates all msg fees with the given handler function.
func (Keeper) Params ¶
func (k Keeper) Params(ctx context.Context, request *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) QueryAllMsgFees ¶
func (k Keeper) QueryAllMsgFees(c context.Context, req *types.QueryAllMsgFeesRequest) (*types.QueryAllMsgFeesResponse, error)
func (Keeper) RemoveMsgFee ¶
RemoveMsgFee removes MsgFee or returns an error if it does not exist