pub(crate) struct DeliveryThread<'a> {
pub(crate) ring: Arc<DeliveryRing>,
pub(crate) inner: &'a Inner,
pub(crate) join: Option<JoinHandle<()>>,
}Expand description
Owns the delivery thread for the lifetime of one capture run and tears it down on
Drop, so teardown also happens when the capture thread UNWINDS.
Closing the ring is the delivery thread’s only wake-up: skip it and the thread parks
in pop() forever, pinning the Python callback and leaving deliver_tid set to a tid
the OS may hand to an unrelated thread (whose stop_capture would then be mistaken
for a re-entrant self-stop and silently do nothing).
Fields§
§ring: Arc<DeliveryRing>§inner: &'a Inner§join: Option<JoinHandle<()>>Trait Implementations§
Source§impl Drop for DeliveryThread<'_>
impl Drop for DeliveryThread<'_>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for DeliveryThread<'a>
impl<'a> !UnwindSafe for DeliveryThread<'a>
impl<'a> Freeze for DeliveryThread<'a>
impl<'a> Send for DeliveryThread<'a>
impl<'a> Sync for DeliveryThread<'a>
impl<'a> Unpin for DeliveryThread<'a>
impl<'a> UnsafeUnpin for DeliveryThread<'a>
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