Trait pallet_time_release::module::Config
source · pub trait Config: Config {
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
type RuntimeFreezeReason: From<FreezeReason>;
type Balance: Balance + MaybeSerializeDeserialize;
type Currency: MutateFreeze<Self::AccountId, Id = Self::RuntimeFreezeReason> + InspectFungible<Self::AccountId, Balance = Self::Balance> + Mutate<Self::AccountId>;
type MinReleaseTransfer: Get<<<Self as Config>::Currency as InspectFungible<<Self as Config>::AccountId>>::Balance>;
type TransferOrigin: EnsureOrigin<Self::RuntimeOrigin, Success = Self::AccountId>;
type WeightInfo: WeightInfo;
type MaxReleaseSchedules: Get<u32>;
type BlockNumberProvider: BlockNumberProvider<BlockNumber = BlockNumberFor<Self>>;
}
Expand description
Configuration trait of this pallet.
The main purpose of this trait is to act as an interface between this pallet and the runtime in which it is embedded in. A type, function, or constant in this trait is essentially left to be configured by the runtime that includes this pallet.
Consequently, a runtime that wants to include this pallet must implement this trait.
Required Associated Types§
sourcetype RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
The overarching event type.
sourcetype RuntimeFreezeReason: From<FreezeReason>
type RuntimeFreezeReason: From<FreezeReason>
The overarching freeze reason.
sourcetype Balance: Balance + MaybeSerializeDeserialize
type Balance: Balance + MaybeSerializeDeserialize
We need MaybeSerializeDeserialize because of the genesis config.
sourcetype Currency: MutateFreeze<Self::AccountId, Id = Self::RuntimeFreezeReason> + InspectFungible<Self::AccountId, Balance = Self::Balance> + Mutate<Self::AccountId>
type Currency: MutateFreeze<Self::AccountId, Id = Self::RuntimeFreezeReason> + InspectFungible<Self::AccountId, Balance = Self::Balance> + Mutate<Self::AccountId>
The currency trait used to set a freeze on a balance.
sourcetype MinReleaseTransfer: Get<<<Self as Config>::Currency as InspectFungible<<Self as Config>::AccountId>>::Balance>
type MinReleaseTransfer: Get<<<Self as Config>::Currency as InspectFungible<<Self as Config>::AccountId>>::Balance>
The minimum amount transferred to call transfer
.
sourcetype TransferOrigin: EnsureOrigin<Self::RuntimeOrigin, Success = Self::AccountId>
type TransferOrigin: EnsureOrigin<Self::RuntimeOrigin, Success = Self::AccountId>
Required origin for time-release transfer.
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
Weight information for extrinsics in this module.
sourcetype MaxReleaseSchedules: Get<u32>
type MaxReleaseSchedules: Get<u32>
The maximum release schedules.
sourcetype BlockNumberProvider: BlockNumberProvider<BlockNumber = BlockNumberFor<Self>>
type BlockNumberProvider: BlockNumberProvider<BlockNumber = BlockNumberFor<Self>>
The block-number provider.
Object Safety§
This trait is not object safe.