Struct evento::Subscriber
source · pub struct Subscriber { /* private fields */ }Implementations§
source§impl Subscriber
impl Subscriber
pub fn new<K: Into<String>>(key: K) -> Self
pub fn filter<T: Into<String>>(self, filter: T) -> Self
pub fn handler( self, handler: fn(e: Event, ctx: EventoContext) -> Pin<Box<dyn Future<Output = Result<Option<Event>, SubscirberHandlerError>> + Send>> ) -> Self
pub fn post_handler( self, handler: fn(e: Event, ctx: EventoContext) -> Pin<Box<dyn Future<Output = Result<(), SubscirberHandlerError>> + Send>> ) -> Self
pub fn set_from_start(self, value: bool) -> Self
Trait Implementations§
source§impl Clone for Subscriber
impl Clone for Subscriber
source§fn clone(&self) -> Subscriber
fn clone(&self) -> Subscriber
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl RefUnwindSafe for Subscriber
impl Send for Subscriber
impl Sync for Subscriber
impl Unpin for Subscriber
impl UnwindSafe for Subscriber
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more