Trait pallet_certification::pallet::Config
source · pub trait Config: Config {
type CertPeriod: Get<BlockNumberFor<Self>>;
type IdtyIndex: Parameter + Member + AtLeast32BitUnsigned + Codec + Default + Copy + MaybeSerializeDeserialize + Debug + MaxEncodedLen;
type IdtyAttr: Idty<Self::IdtyIndex, Self::AccountId>;
type CheckCertAllowed: CheckCertAllowed<Self::IdtyIndex>;
type MaxByIssuer: Get<u32>;
type MinReceivedCertToBeAbleToIssueCert: Get<u32>;
type OnNewcert: OnNewcert<Self::IdtyIndex>;
type OnRemovedCert: OnRemovedCert<Self::IdtyIndex>;
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
type WeightInfo: WeightInfo;
type ValidityPeriod: Get<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 CertPeriod: Get<BlockNumberFor<Self>>
type CertPeriod: Get<BlockNumberFor<Self>>
Minimum duration between two certifications issued by the same issuer.
sourcetype IdtyIndex: Parameter + Member + AtLeast32BitUnsigned + Codec + Default + Copy + MaybeSerializeDeserialize + Debug + MaxEncodedLen
type IdtyIndex: Parameter + Member + AtLeast32BitUnsigned + Codec + Default + Copy + MaybeSerializeDeserialize + Debug + MaxEncodedLen
A short identity index.
sourcetype IdtyAttr: Idty<Self::IdtyIndex, Self::AccountId>
type IdtyAttr: Idty<Self::IdtyIndex, Self::AccountId>
Something that gives the IdtyId of an AccountId and reverse
sourcetype CheckCertAllowed: CheckCertAllowed<Self::IdtyIndex>
type CheckCertAllowed: CheckCertAllowed<Self::IdtyIndex>
Provide method to check that cert is allowed.
sourcetype MaxByIssuer: Get<u32>
type MaxByIssuer: Get<u32>
Maximum number of active certifications by issuer.
sourcetype MinReceivedCertToBeAbleToIssueCert: Get<u32>
type MinReceivedCertToBeAbleToIssueCert: Get<u32>
Minimum number of certifications received to be allowed to issue a certification.
sourcetype OnRemovedCert: OnRemovedCert<Self::IdtyIndex>
type OnRemovedCert: OnRemovedCert<Self::IdtyIndex>
Handler for Removed event.
sourcetype RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
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.
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
Type representing the weight of this pallet.
sourcetype ValidityPeriod: Get<BlockNumberFor<Self>>
type ValidityPeriod: Get<BlockNumberFor<Self>>
Duration of validity of a certification.