[][src]Trait frame_support::traits::FilterStack

pub trait FilterStack<T>: Filter<T> {
    type Stack;
    fn push(constraint: impl Fn(&T) -> bool + 'static);
fn pop();
fn take() -> Self::Stack;
fn restore(taken: Self::Stack); }

Trait to add a constraint onto the filter.

Associated Types

type Stack

The type used to archive the stack.

Loading content...

Required methods

fn push(constraint: impl Fn(&T) -> bool + 'static)

Add a new constraint onto the filter.

fn pop()

Removes the most recently pushed, and not-yet-popped, constraint from the filter.

fn take() -> Self::Stack

Clear the filter, returning a value that may be used later to restore it.

fn restore(taken: Self::Stack)

Restore the filter from a previous take operation.

Loading content...

Implementors

Loading content...