[−][src]Struct cpal::Host
The platform's dynamically dispatched Host type.
An instance of this Host type may represent one of any of the Hosts available on the platform.
Use this type if you require switching between available hosts at runtime.
This type may be constructed via the host_from_id function. HostIds may be acquired via the ALL_HOSTS const and the available_hosts function.
Implementations
impl Host
[src]
Trait Implementations
impl From<Host> for Host
[src]
impl HostTrait for Host
[src]
type Devices = Devices
The type used for enumerating available devices by the host.
type Device = Device
The Device
type yielded by the host.
fn is_available() -> bool
[src]
fn devices(&self) -> Result<Self::Devices, DevicesError>
[src]
fn default_input_device(&self) -> Option<Self::Device>
[src]
fn default_output_device(&self) -> Option<Self::Device>
[src]
fn input_devices(&self) -> Result<InputDevices<Self::Devices>, DevicesError>
[src]
fn output_devices(&self) -> Result<OutputDevices<Self::Devices>, DevicesError>
[src]
Auto Trait Implementations
impl RefUnwindSafe for Host
impl Send for Host
impl Sync for Host
impl Unpin for Host
impl UnwindSafe for Host
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>,