#[non_exhaustive]pub enum AudioError {
NotAllowed,
Network,
Decode,
NotSupported,
QuotaExceeded,
Unavailable,
Failed,
}Expand description
Why a sound or a player failed (TS: the error’s code, named as the
Web’s MediaError).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NotAllowed
The app’s capabilities, or the browser before a gesture, do not
allow it (not-allowed).
Network
Its source could not be fetched (network).
Decode
Its bytes are not audio the platform decodes (decode).
NotSupported
Its format is not one the platform plays (not-supported).
QuotaExceeded
Past a limit of the engine’s (quota-exceeded).
Nothing plays sound here (unavailable).
Failed
Another reason, such as the output going away (failed).
Implementations§
Source§impl AudioError
impl AudioError
Trait Implementations§
Source§impl Clone for AudioError
impl Clone for AudioError
impl Copy for AudioError
Source§impl Debug for AudioError
impl Debug for AudioError
impl Eq for AudioError
Source§impl Hash for AudioError
impl Hash for AudioError
Source§impl PartialEq for AudioError
impl PartialEq for AudioError
impl StructuralPartialEq for AudioError
Auto Trait Implementations§
impl Forget for AudioError
impl Freeze for AudioError
impl Move for AudioError
impl RefUnwindSafe for AudioError
impl Send for AudioError
impl Sync for AudioError
impl Unpin for AudioError
impl UnsafeUnpin for AudioError
impl UnwindSafe for AudioError
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