Documentation ¶
Index ¶
- Variables
- func NewMsgServerImpl(k Keeper) types.MsgServer
- type DeductTaxDecorator
- type Keeper
- func (k Keeper) BaseDenom(ctx context.Context) string
- func (k Keeper) ContractAddress(ctx context.Context) string
- func (k Keeper) CustomTxFeeChecker(ctx sdk.Context, tx sdk.Tx) (sdk.Coins, int64, error)
- func (k Keeper) FeeRate(ctx context.Context) int32
- func (k Keeper) GetAuthority() string
- func (k Keeper) GetParams(ctx context.Context) (params types.Params, err error)
- func (k Keeper) Logger(ctx context.Context) log.Logger
- func (k Keeper) Params(ctx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) SetParams(ctx context.Context, params types.Params) error
- type Migrator
Constants ¶
This section is empty.
Variables ¶
var HUNDRED_DEC = sdkmath.LegacyNewDec(100)
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the x/tax MsgServer interface.
Types ¶
type DeductTaxDecorator ¶
type DeductTaxDecorator struct {
// contains filtered or unexported fields
}
DeductTaxDecorator deducts tax by a given fee rate from the standard collected fee. The tax is sent to a treasury account Call next AnteHandler if tax successfully sent to treasury or no fee provided CONTRACT: Tx must implement FeeTx interface to use DeductTaxDecorator.
func NewDeductTaxDecorator ¶
func NewDeductTaxDecorator(ak types.AccountKeeper, bk types.BankKeeper, tk Keeper) DeductTaxDecorator
func (DeductTaxDecorator) AnteHandle ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, storeService store.KVStoreService, wasmKeeper types.WasmKeeper, authority string, ) Keeper
func (Keeper) ContractAddress ¶
ContractAddress returns the contract address.
func (Keeper) CustomTxFeeChecker ¶ added in v0.5.0
CustomTxFeeChecker reuses the default fee logic, but we will add the ability to pay fees in other denoms defined as a module parameter. The exact price will be calculated in base asset(defined in the min-gas-prices of the validators' config).
func (Keeper) GetAuthority ¶ added in v0.5.0
GetAuthority returns the x/tax module's authority.
func (Keeper) Params ¶
func (k Keeper) Params(ctx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
type Migrator ¶ added in v0.5.0
type Migrator struct {
// contains filtered or unexported fields
}
Migrator is a struct for handling in-place state migrations.
func (Migrator) Migrate2to3 ¶ added in v0.5.0
Migrate1to2 migrates the x/tax module state from the consensus version 1 to version 2. Specifically, it takes the parameters that are currently stored and managed by the x/params modules and stores them directly into the x/tax module state.