[−][src]Struct nakadion::handler::HandlerFn
Simple wrapper for BatchHandlers
from closures
Trait Implementations
impl<F> BatchHandler for HandlerFn<F> where
F: for<'a> FnMut(Bytes, BatchMeta<'a>) -> BatchHandlerFuture<'a> + Send,
[src]
F: for<'a> FnMut(Bytes, BatchMeta<'a>) -> BatchHandlerFuture<'a> + Send,
fn handle<'a>(
&'a mut self,
events: Bytes,
meta: BatchMeta<'a>
) -> BatchHandlerFuture<'a>
[src]
&'a mut self,
events: Bytes,
meta: BatchMeta<'a>
) -> BatchHandlerFuture<'a>
fn on_inactive(
&mut self,
_inactive_for: Duration,
_last_activity: Instant
) -> InactivityAnswer
[src]
&mut self,
_inactive_for: Duration,
_last_activity: Instant
) -> InactivityAnswer
Auto Trait Implementations
impl<F> RefUnwindSafe for HandlerFn<F> where
F: RefUnwindSafe,
F: RefUnwindSafe,
impl<F> Send for HandlerFn<F> where
F: Send,
F: Send,
impl<F> Sync for HandlerFn<F> where
F: Sync,
F: Sync,
impl<F> Unpin for HandlerFn<F> where
F: Unpin,
F: Unpin,
impl<F> UnwindSafe for HandlerFn<F> where
F: UnwindSafe,
F: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BatchHandler for T where
T: EventsHandler + Send + 'static,
<T as EventsHandler>::Event: DeserializeOwned,
<T as EventsHandler>::Event: Send,
<T as EventsHandler>::Event: 'static,
[src]
T: EventsHandler + Send + 'static,
<T as EventsHandler>::Event: DeserializeOwned,
<T as EventsHandler>::Event: Send,
<T as EventsHandler>::Event: 'static,
fn handle(
&'a mut Self,
Bytes,
BatchMeta<'a>
) -> Pin<Box<dyn Future<Output = BatchPostAction> + 'a + Send>>
[src]
&'a mut Self,
Bytes,
BatchMeta<'a>
) -> Pin<Box<dyn Future<Output = BatchPostAction> + 'a + Send>>
fn on_inactive(&mut Self, Duration, Instant) -> InactivityAnswer
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> SendSyncUnwindSafe for T where
T: Send + Sync + UnwindSafe + ?Sized,
T: Send + Sync + UnwindSafe + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,