pub trait Config: Config {
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
type PalletId: Get<PalletId>;
type WeightInfo: WeightInfo;
type Currency: ReservableCurrency<Self::AccountId>;
type Torus: Torus0Api<Self::AccountId, BalanceOf<Self>>;
type MaxControllersPerPermission: Get<u32>;
type MaxRevokersPerPermission: Get<u32>;
type MaxTargetsPerPermission: Get<u32>;
type MaxStreamsPerPermission: Get<u32>;
type MinAutoDistributionThreshold: Get<BalanceOf<Self>>;
type MaxNamespacesPerPermission: Get<u32>;
}
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. Configure the pallet by specifying the parameters and types on which it depends.
Required Associated Types§
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
type WeightInfo: WeightInfo
type Currency: ReservableCurrency<Self::AccountId>
type Torus: Torus0Api<Self::AccountId, BalanceOf<Self>>
Sourcetype MaxControllersPerPermission: Get<u32>
type MaxControllersPerPermission: Get<u32>
Maximum number of controllers per permission.
Sourcetype MaxRevokersPerPermission: Get<u32>
type MaxRevokersPerPermission: Get<u32>
Maximum number of revokers.
Sourcetype MaxTargetsPerPermission: Get<u32>
type MaxTargetsPerPermission: Get<u32>
Maximum number of targets per permission.
Sourcetype MaxStreamsPerPermission: Get<u32>
type MaxStreamsPerPermission: Get<u32>
Maximum number of delegated streams per permission.
Sourcetype MinAutoDistributionThreshold: Get<BalanceOf<Self>>
type MinAutoDistributionThreshold: Get<BalanceOf<Self>>
Minimum threshold for auto-distribution
Sourcetype MaxNamespacesPerPermission: Get<u32>
type MaxNamespacesPerPermission: Get<u32>
Maximum number of namespaces a single permission can delegate.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.