pub struct FrameBus { /* private fields */ }Implementations§
Source§impl FrameBus
impl FrameBus
pub fn new(max_frames: usize, max_bytes: usize) -> Arc<Self> ⓘ
pub fn subscribe(self: &Arc<Self>) -> FrameReceiver
pub fn receiver_count(&self) -> usize
pub fn close(&self)
pub fn is_closed(&self) -> bool
Sourcepub fn send(&self, frame: Arc<AccessUnit>) -> Result<(), FrameRecvError>
pub fn send(&self, frame: Arc<AccessUnit>) -> Result<(), FrameRecvError>
Publish one frame, evicting the oldest entries until both budgets fit. Returns the number of receivers that were notified (0 is valid).
Auto Trait Implementations§
impl !Freeze for FrameBus
impl Forget for FrameBus
impl Move for FrameBus
impl RefUnwindSafe for FrameBuswhere
Mutex<State>: RefUnwindSafe,
Notify: RefUnwindSafe,
Atomic<usize>: RefUnwindSafe,
Atomic<bool>: RefUnwindSafe,
impl Send for FrameBus
impl Sync for FrameBus
impl Unpin for FrameBus
impl UnsafeUnpin for FrameBuswhere
Align4<u32>: UnsafeUnpin,
Align1<u8>: UnsafeUnpin,
*const u8 is !null: UnsafeUnpin,
PhantomData<Arc<AccessUnit>>: UnsafeUnpin,
Align8<usize>: UnsafeUnpin,
*const Waiter is !null: UnsafeUnpin,
impl UnwindSafe for FrameBuswhere
Mutex<State>: UnwindSafe,
Notify: UnwindSafe,
Align8<usize>: UnwindSafe,
Align1<u8>: UnwindSafe,
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