Attribute Macro frame_support::pallet_macros::generate_deposit
source · #[generate_deposit]
Expand description
The attribute #[pallet::generate_deposit($visibility fn deposit_event)]
generates a
helper function on Pallet
that handles deposit events.
NOTE: For instantiable pallets, the event must be generic over T
and I
.
Macro expansion
The macro will add on enum Event
the attributes:
#[derive(frame_support::CloneNoBound)]
#[derive(frame_support::EqNoBound)]
#[derive(frame_support::PartialEqNoBound)]
#[derive(frame_support::RuntimeDebugNoBound)]
#[derive(codec::Encode)]
#[derive(codec::Decode)]
The macro implements From<Event<..>>
for ().
The macro implements a metadata function on Event
returning the EventMetadata
.
If #[pallet::generate_deposit]
is present then the macro implements fn deposit_event
on
Pallet
.