paramHub

package
v0.1.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2023 License: MPL-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Operate fee
	ProposeFee           = 10e8
	DepositFee           = 125e3
	SideProposeFee       = 10e8
	SideDepositFee       = 125e3
	SideVoteFee          = 1e8
	ListingFee           = 2000e8
	IssueFee             = 1000e8
	MintFee              = 200e8
	BurnFee              = 1e8
	FreezeFee            = 1e6
	TimeLockFee          = 1e6
	TimeUnlockFee        = 1e6
	TimeRelockFee        = 1e6
	TransferOwnershipFee = 1e6

	SetAccountFlagsFee = 1e8

	HTLTFee        = 37500
	DepositHTLTFee = 37500
	ClaimHTLTFee   = 37500
	RefundHTLTFee  = 37500

	// stake fee
	CreateValidatorFee          = 10e8
	RemoveValidatorFee          = 1e8
	CreateSideChainValidatorFee = 10e8
	EditSideChainValidatorFee   = 1e8
	SideChainDelegateFee        = 1e5
	SideChainRedelegateFee      = 3e5
	SideChainUndelegateFee      = 2e5

	// beacon chain stake fee
	EditChainValidatorFee = 1e8
	ChainDelegateFee      = 1e5
	ChainRedelegateFee    = 3e5
	ChainUndelegateFee    = 2e5

	// slashing fee
	AxcSubmitEvidenceFee = 10e8
	SideChainUnjail      = 1e8
	Unjail               = 1e8

	// Transfer fee
	TransferFee       = 62500
	MultiTransferFee  = 50000 // discount 80%
	LowerLimitAsMulti = 2

	// Dex fee
	ExpireFee          = 5e4
	ExpireFeeNative    = 1e4
	CancelFee          = 5e4
	CancelFeeNative    = 1e4
	FeeRate            = 1000
	FeeRateNative      = 400
	IOCExpireFee       = 25e3
	IOCExpireFeeNative = 5e3

	// cross chain
	CrossBindFee        = 1e8
	CrossUnbindFee      = 1e8
	CrossTransferOutFee = 2e4

	CrossTransferOutRelayFee = 1e5
	CrossBindRelayFee        = 2e6
	CrossUnbindRelayFee      = 2e6

	//MiniToken fee
	TinyIssueFee   = 2e8
	MiniIssueFee   = 3e8
	MiniSetUriFee  = 37500
	MiniListingFee = 8e8

	// Cross stake fee
	CrossDistributeRewardRelayFee      = 6e5 // 0.006 AXC
	CrossDistributeUndelegatedRelayFee = 6e5 // 0.006 AXC
)
View Source
const AbciQueryPrefix = "param"

Variables

View Source
var DefaultGenesisState = param.GenesisState{
	FeeGenesis: FeeGenesisState,
}
View Source
var FeeGenesisState = []param.FeeParam{

	&param.FixedFeeParams{"submit_proposal", ProposeFee, sdk.FeeForProposer},
	&param.FixedFeeParams{"deposit", DepositFee, sdk.FeeForProposer},
	&param.FixedFeeParams{"vote", sdk.ZeroFee, sdk.FeeFree},
	&param.FixedFeeParams{"create_validator", CreateValidatorFee, sdk.FeeForProposer},
	&param.FixedFeeParams{"remove_validator", RemoveValidatorFee, sdk.FeeForProposer},
	&param.FixedFeeParams{"dexList", ListingFee, sdk.FeeForAll},
	&param.FixedFeeParams{"orderNew", sdk.ZeroFee, sdk.FeeFree},
	&param.FixedFeeParams{"orderCancel", sdk.ZeroFee, sdk.FeeFree},
	&param.FixedFeeParams{"issueMsg", IssueFee, sdk.FeeForAll},
	&param.FixedFeeParams{"mintMsg", MintFee, sdk.FeeForAll},
	&param.FixedFeeParams{"tokensBurn", BurnFee, sdk.FeeForProposer},
	&param.FixedFeeParams{"tokensFreeze", FreezeFee, sdk.FeeForProposer},

	&param.TransferFeeParam{
		FixedFeeParams: param.FixedFeeParams{
			MsgType: "send",
			Fee:     TransferFee,
			FeeFor:  sdk.FeeForProposer},
		MultiTransferFee:  MultiTransferFee,
		LowerLimitAsMulti: LowerLimitAsMulti,
	},

	&param.DexFeeParam{
		DexFeeFields: []param.DexFeeField{
			{"ExpireFee", ExpireFee},
			{"ExpireFeeNative", ExpireFeeNative},
			{"CancelFee", CancelFee},
			{"CancelFeeNative", CancelFeeNative},
			{"FeeRate", FeeRate},
			{"FeeRateNative", FeeRateNative},
			{"IOCExpireFee", IOCExpireFee},
			{"IOCExpireFeeNative", IOCExpireFeeNative},
		},
	},
}

--------- Definition about fee prams ------------------- //

Functions

func CreateAbciQueryHandler

func CreateAbciQueryHandler(paramHub *ParamHub) func(sdk.Context, abci.RequestQuery, []string) *abci.ResponseQuery

tolerate the previous RPC api.

func EndBlock

func EndBlock(ctx sdk.Context, paramHub *ParamHub)

func EndBreatheBlock

func EndBreatheBlock(ctx sdk.Context, paramHub *ParamHub)

func NewQuerier

func NewQuerier(hub *ParamHub, cdc *codec.Codec) sdk.Querier

func RegisterUpgradeBeginBlocker

func RegisterUpgradeBeginBlocker(paramHub *ParamHub)

func RegisterWire

func RegisterWire(cdc *amino.Codec)

Register concrete types on wire codec

Types

type BCParamsChangeHooks

type BCParamsChangeHooks struct {
	// contains filtered or unexported fields
}

--------------------- BCParamsChangeHook -----------------

func NewBCParamsChangeHook

func NewBCParamsChangeHook(cdc *amino.Codec) BCParamsChangeHooks

func (BCParamsChangeHooks) OnProposalSubmitted

func (hooks BCParamsChangeHooks) OnProposalSubmitted(ctx sdk.Context, proposal gov.Proposal) error

type CSCParamsChangeHooks

type CSCParamsChangeHooks struct {
	// contains filtered or unexported fields
}

--------------------- CSCParamsChangeHook -----------------

func NewCSCParamsChangeHook

func NewCSCParamsChangeHook(cdc *amino.Codec) CSCParamsChangeHooks

func (CSCParamsChangeHooks) OnProposalSubmitted

func (hooks CSCParamsChangeHooks) OnProposalSubmitted(ctx sdk.Context, proposal gov.Proposal) error

type FeeChangeHooks

type FeeChangeHooks struct {
	// contains filtered or unexported fields
}

--------------------- FeeChangeHooks -----------------

func NewFeeChangeHooks

func NewFeeChangeHooks(cdc *amino.Codec) FeeChangeHooks

func (FeeChangeHooks) OnProposalSubmitted

func (hooks FeeChangeHooks) OnProposalSubmitted(ctx sdk.Context, proposal gov.Proposal) error

type ParamHub

type ParamHub = keeper.Keeper

type SCParamsChangeHooks

type SCParamsChangeHooks struct {
	// contains filtered or unexported fields
}

--------------------- SCParamsChangeHook -----------------

func NewSCParamsChangeHook

func NewSCParamsChangeHook(cdc *amino.Codec) SCParamsChangeHooks

func (SCParamsChangeHooks) OnProposalSubmitted

func (hooks SCParamsChangeHooks) OnProposalSubmitted(ctx sdk.Context, proposal gov.Proposal) error

Directories

Path Synopsis
client
cli
nolint
nolint

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL