pub struct StreamQueues {
pub pcm: BoundedSender<PcmPacket>,
pub pcm_receiver: BoundedReceiver<PcmPacket>,
pub events: BoundedSender<SynthesisEvent>,
pub event_receiver: BoundedReceiver<SynthesisEvent>,
}Expand description
A streaming endpoint pair with independent bounded PCM and event queues.
The queue separation makes an event consumer stall unable to block PCM delivery (and vice versa). Producers park under backpressure and observe request cancellation while waiting; no unbounded buffering is available.
Fields§
§pcm: BoundedSender<PcmPacket>PCM producer endpoint.
pcm_receiver: BoundedReceiver<PcmPacket>PCM consumer endpoint.
events: BoundedSender<SynthesisEvent>Event producer endpoint.
event_receiver: BoundedReceiver<SynthesisEvent>Event consumer endpoint.
Implementations§
Source§impl StreamQueues
impl StreamQueues
Sourcepub fn new(capacity: usize) -> Result<Self, EngineError>
pub fn new(capacity: usize) -> Result<Self, EngineError>
Creates distinct bounded queues for PCM and lifecycle events.
Auto Trait Implementations§
impl !Sync for StreamQueues
impl Freeze for StreamQueues
impl RefUnwindSafe for StreamQueues
impl Send for StreamQueues
impl Unpin for StreamQueues
impl UnsafeUnpin for StreamQueues
impl UnwindSafe for StreamQueues
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, _span: NoopSpan) -> Self
fn instrument(self, _span: NoopSpan) -> Self
Instruments this future with a span (no-op when disabled).
Source§fn in_current_span(self) -> Self
fn in_current_span(self) -> Self
Instruments this future with the current span (no-op when disabled).