Trait technical::pallet::Config

source ·
pub trait Config: Config + Config + Config {
    type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
    type TechAssetId: Copy + Ord + Member + Parameter + Into<<Self as Config>::AssetId> + From<<Self as Config>::AssetId>;
    type TechAccountId: Ord + Member + Parameter + Default + FromGenericPair + MaybeSerializeDeserialize + ToFeeAccount + ToXykTechUnitFromDEXAndTradingPair<<Self as Config>::DEXId, TradingPair<Self::TechAssetId>> + ToOrderTechUnitFromDEXAndTradingPair<<Self as Config>::DEXId, TradingPair<Self::TechAssetId>> + Into<TechAccountId<Self::AccountId, Self::TechAssetId, Self::DEXId>>;
    type Trigger: Default + Copy + Member + Parameter;
    type Condition: Default + Copy + Member + Parameter;
    type SwapAction: SwapRulesValidation<Self::AccountId, Self::TechAccountId, Self::AssetId, Self> + Parameter;
}
Expand description

Configuration trait of this pallet.

Implement this type for a runtime in order to customize this pallet.

Required Associated Types§

source

type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>

Because this pallet emits events, it depends on the runtime’s definition of an event.

source

type TechAssetId: Copy + Ord + Member + Parameter + Into<<Self as Config>::AssetId> + From<<Self as Config>::AssetId>

Like Asset but deterministically maked from purpose.

source

type TechAccountId: Ord + Member + Parameter + Default + FromGenericPair + MaybeSerializeDeserialize + ToFeeAccount + ToXykTechUnitFromDEXAndTradingPair<<Self as Config>::DEXId, TradingPair<Self::TechAssetId>> + ToOrderTechUnitFromDEXAndTradingPair<<Self as Config>::DEXId, TradingPair<Self::TechAssetId>> + Into<TechAccountId<Self::AccountId, Self::TechAssetId, Self::DEXId>>

Like AccountId but controlled by consensus, not signing by user. This extra traits exist here bacause no way to do it by constraints, problem exist with constraints and substrate macroses, and place this traits here is solution.

source

type Trigger: Default + Copy + Member + Parameter

Trigger for auto claim.

source

type Condition: Default + Copy + Member + Parameter

Condition for auto claim.

source

type SwapAction: SwapRulesValidation<Self::AccountId, Self::TechAccountId, Self::AssetId, Self> + Parameter

Swap action.

Implementors§