Trait Config

Source
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§

Source

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

Source

type PalletId: Get<PalletId>

Permission0 pallet ID

Source

type WeightInfo: WeightInfo

Source

type Currency: ReservableCurrency<Self::AccountId>

Source

type Torus: Torus0Api<Self::AccountId, BalanceOf<Self>>

Source

type MaxControllersPerPermission: Get<u32>

Maximum number of controllers per permission.

Source

type MaxRevokersPerPermission: Get<u32>

Maximum number of revokers.

Source

type MaxTargetsPerPermission: Get<u32>

Maximum number of targets per permission.

Source

type MaxStreamsPerPermission: Get<u32>

Maximum number of delegated streams per permission.

Source

type MinAutoDistributionThreshold: Get<BalanceOf<Self>>

Minimum threshold for auto-distribution

Source

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.

Implementors§