pub enum CodecRequest {
SetFormat {
format: DaiFormat,
responder: Box<dyn FnOnce(Result<(), Status>) + Send>,
},
Start {
responder: Box<dyn FnOnce(Result<MonotonicInstant, Status>) + Send>,
},
Stop {
responder: Box<dyn FnOnce(Result<MonotonicInstant, Status>) + Send>,
},
}
Expand description
Request from the Audio subsystem to query or perform an action on the codec.
Variants§
SetFormat
Set the format of this codec.
Fields
Start
Start the codec.
Fields
§
responder: Box<dyn FnOnce(Result<MonotonicInstant, Status>) + Send>
Responder to be called when the codec has been started, providing the time started or an error if it failed to start. The time is system monotonic when configuring the codec to start completed (it does not include startup delay time) Replying Err() to this will close the codec, and it will need to be re-instantiated.
Stop
Stop the codec.
Fields
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CodecRequest
impl !RefUnwindSafe for CodecRequest
impl Send for CodecRequest
impl !Sync for CodecRequest
impl Unpin for CodecRequest
impl !UnwindSafe for CodecRequest
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