pub struct Consumer<'a, F>{
pub count: Option<usize>,
pub group: Option<(String, String)>,
pub handled_messages: u32,
pub handler: F,
pub next_pos: String,
pub process_pending: bool,
pub redis: &'a mut Connection,
pub stream: String,
pub timeout: usize,
}Fields§
§count: Option<usize>§group: Option<(String, String)>§handled_messages: u32§handler: F§next_pos: String§process_pending: bool§redis: &'a mut Connection§stream: String§timeout: usizeImplementations§
Source§impl<'a, F> Consumer<'a, F>
impl<'a, F> Consumer<'a, F>
Sourcepub fn init(
redis: &'a mut Connection,
stream: &str,
handler: F,
opts: ConsumerOpts,
) -> Result<Self>
pub fn init( redis: &'a mut Connection, stream: &str, handler: F, opts: ConsumerOpts, ) -> Result<Self>
Initializes a new stream::Consumer.
Auto Trait Implementations§
impl<'a, F> Freeze for Consumer<'a, F>where
F: Freeze,
impl<'a, F> !RefUnwindSafe for Consumer<'a, F>
impl<'a, F> Send for Consumer<'a, F>where
F: Send,
impl<'a, F> Sync for Consumer<'a, F>where
F: Sync,
impl<'a, F> Unpin for Consumer<'a, F>where
F: Unpin,
impl<'a, F> !UnwindSafe for Consumer<'a, F>
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