pub trait Config<I: 'static = ()>: Config {
type BridgedChain: Chain;
type HeadersToStore: Get<u32>;
type WeightInfo: WeightInfo;
type FastConfirmationOffset: Get<BlockNumberFor<Self>>;
type RationalConfirmationOffset: Get<BlockNumberFor<Self>>;
type FinalizedConfirmationOffset: Get<BlockNumberFor<Self>>;
type EpochOffset: Get<BlockNumberFor<Self>>;
type LightClientAsyncAPI: LightClientAsyncAPI<Self>;
type MyVendor: Get<GatewayVendor>;
type RuntimeEvent: From<Event<Self, I>> + IsType<<Self as Config>::RuntimeEvent>;
}
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 BridgedChain: Chain
type BridgedChain: Chain
The chain we are bridging to here.
sourcetype HeadersToStore: Get<u32>
type HeadersToStore: Get<u32>
Maximal number of finalized headers to keep in the storage.
The setting is there to prevent growing the on-chain state indefinitely. Note the setting does not relate to block numbers - we will simply keep as much items in the storage, so it doesn’t guarantee any fixed timeframe for finality headers.
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
Weights gathered through benchmarking.