Struct dome_cloomnik::CallbackChannel [−][src]
A DOME audio channel, as passed to the channel callbacks (mix
and update
).
Implementations
impl<T: Send + Sync> CallbackChannel<T>
[src]
pub fn state(&self) -> ChannelState
[src]
Queries the state of this channel.
pub fn set_state(&mut self, state: ChannelState)
[src]
Sets the state for this channel.
pub fn stop(&mut self)
[src]
Stops the channel. This is equivalent to self.set_state(ChannelState::Stopped)
.
pub fn data(&self) -> RwLockReadGuard<'_, T>
[src]
Gets the user data associated with this channel, for read only.
Channels are using RwLock
to hold user data,
so you can have multiple read-only references but only one read-write
reference at a time.
pub fn data_mut(&self) -> RwLockWriteGuard<'_, T>
[src]
Gets the user data associated with this channel, for read and write.
Channels are using RwLock
to hold user data,
so you can have multiple read-only references but only one read-write
reference at a time.
Trait Implementations
Auto Trait Implementations
impl<T> !RefUnwindSafe for CallbackChannel<T>
[src]
impl<T> !Send for CallbackChannel<T>
[src]
impl<T> !Sync for CallbackChannel<T>
[src]
impl<T> Unpin for CallbackChannel<T> where
T: Unpin,
[src]
T: Unpin,
impl<T> UnwindSafe for CallbackChannel<T> where
T: UnwindSafe,
[src]
T: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,