Trait jsonrpc_ws_server::MetaExtractor[][src]

pub trait MetaExtractor<M: Metadata>: Send + Sync + 'static {
    fn extract(&self, _context: &RequestContext) -> M;
}

Metadata extractor from session data.

Required methods

fn extract(&self, _context: &RequestContext) -> M[src]

Extract metadata for given session

Loading content...

Implementors

impl<M, F> MetaExtractor<M> for F where
    M: Metadata,
    F: Fn(&RequestContext) -> M + Send + Sync + 'static, 
[src]

impl<M: Metadata + Default> MetaExtractor<M> for NoopExtractor[src]

Loading content...