referrerpolicy=no-referrer-when-downgrade
frame_support::traits

Trait RankedMembersSwapHandler

Source
pub trait RankedMembersSwapHandler<AccountId, Rank> {
    // Required method
    fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank);
}
Expand description

Handler that can deal with the swap of two members.

Required Methods§

Source

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

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.

Implementations on Foreign Types§

Source§

impl<AccountId, Rank> RankedMembersSwapHandler<AccountId, Rank> for ()
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0,)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>, TupleElement10: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>, TupleElement10: RankedMembersSwapHandler<AccountId, Rank>, TupleElement11: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>, TupleElement10: RankedMembersSwapHandler<AccountId, Rank>, TupleElement11: RankedMembersSwapHandler<AccountId, Rank>, TupleElement12: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>, TupleElement10: RankedMembersSwapHandler<AccountId, Rank>, TupleElement11: RankedMembersSwapHandler<AccountId, Rank>, TupleElement12: RankedMembersSwapHandler<AccountId, Rank>, TupleElement13: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>, TupleElement10: RankedMembersSwapHandler<AccountId, Rank>, TupleElement11: RankedMembersSwapHandler<AccountId, Rank>, TupleElement12: RankedMembersSwapHandler<AccountId, Rank>, TupleElement13: RankedMembersSwapHandler<AccountId, Rank>, TupleElement14: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13, TupleElement14)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Source§

impl<AccountId, Rank, TupleElement0: RankedMembersSwapHandler<AccountId, Rank>, TupleElement1: RankedMembersSwapHandler<AccountId, Rank>, TupleElement2: RankedMembersSwapHandler<AccountId, Rank>, TupleElement3: RankedMembersSwapHandler<AccountId, Rank>, TupleElement4: RankedMembersSwapHandler<AccountId, Rank>, TupleElement5: RankedMembersSwapHandler<AccountId, Rank>, TupleElement6: RankedMembersSwapHandler<AccountId, Rank>, TupleElement7: RankedMembersSwapHandler<AccountId, Rank>, TupleElement8: RankedMembersSwapHandler<AccountId, Rank>, TupleElement9: RankedMembersSwapHandler<AccountId, Rank>, TupleElement10: RankedMembersSwapHandler<AccountId, Rank>, TupleElement11: RankedMembersSwapHandler<AccountId, Rank>, TupleElement12: RankedMembersSwapHandler<AccountId, Rank>, TupleElement13: RankedMembersSwapHandler<AccountId, Rank>, TupleElement14: RankedMembersSwapHandler<AccountId, Rank>, TupleElement15: RankedMembersSwapHandler<AccountId, Rank>> RankedMembersSwapHandler<AccountId, Rank> for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13, TupleElement14, TupleElement15)
where Rank: Clone,

Source§

fn swapped(who: &AccountId, new_who: &AccountId, rank: Rank)

Member old was swapped with new at rank.

Implementors§

impl<T: Config<I>, I: 'static> RankedMembersSwapHandler<<T as Config>::AccountId, u16> for Pallet<T, I>

impl<T: Config<I>, I: 'static> RankedMembersSwapHandler<<T as Config>::AccountId, <<T as Config<I>>::Members as RankedMembers>::Rank> for Pallet<T, I>