pub struct SignalsReceiver { /* private fields */ }Expand description
Polls one RFC 8936 stream of CAEP and RISC events.
Implementations§
Source§impl SignalsReceiver
impl SignalsReceiver
Sourcepub fn new(opt: ReceiverOptions) -> Result<Self, SamlError>
pub fn new(opt: ReceiverOptions) -> Result<Self, SamlError>
Builds a receiver. It does not contact the transmitter until start.
pub fn track( &self, local_id: &str, login: &SamlLogin, expires_at_ms: Option<i64>, )
pub fn untrack(&self, local_id: &str)
pub fn on<F>(&self, event_type: &str, handler: F) -> &Self
pub fn stream(&self) -> Map<String, Value>
Sourcepub fn start(&self) -> Result<(), SamlError>
pub fn start(&self) -> Result<(), SamlError>
Discovers the transmitter, ensures one poll stream, and polls once before returning.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for SignalsReceiver
impl !UnwindSafe for SignalsReceiver
impl Forget for SignalsReceiver
impl Freeze for SignalsReceiver
impl Send for SignalsReceiver
impl Sync for SignalsReceiver
impl Unpin for SignalsReceiver
impl UnsafeUnpin for SignalsReceiver
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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