[][src]Trait dispatchtable::Dispatch

pub trait Dispatch<K, P, R> where
    K: Eq
{ fn into_vec(self) -> Vec<(K, Box<dyn DispatchFunction<P, R>>)>;
fn remove(&mut self, key: &K);
fn insert(&mut self, key: K, item: Box<dyn DispatchFunction<P, R>>);
fn contains_key(&self, key: &K) -> bool;
fn get(&self, key: &K) -> Option<&Box<dyn DispatchFunction<P, R>>>;
fn len(&self) -> usize; fn call(&self, key: &K, params: &P) -> Option<R> { ... } }

Required methods

fn into_vec(self) -> Vec<(K, Box<dyn DispatchFunction<P, R>>)>

fn remove(&mut self, key: &K)

fn insert(&mut self, key: K, item: Box<dyn DispatchFunction<P, R>>)

fn contains_key(&self, key: &K) -> bool

fn get(&self, key: &K) -> Option<&Box<dyn DispatchFunction<P, R>>>

fn len(&self) -> usize

Loading content...

Provided methods

fn call(&self, key: &K, params: &P) -> Option<R>

Loading content...

Implementors

impl<K, P, R> Dispatcher<K, P, R> for DispatchTable<K, P, R> where
    K: Hash + Eq
[src]

Loading content...