pub enum Error {
InvalidApplication,
InvalidBandwidth(i32),
InvalidBitrate(i32),
InvalidSignal(i32),
InvalidComplexity(i32),
InvalidSampleRate(i32),
InvalidChannels(i32),
Opus(ErrorCode),
EmptyPacket,
SignalsTooLarge,
PacketTooLarge,
MappingExpectedLen(usize),
}
Variants§
InvalidApplication
A value failed to match a documented Application
.
InvalidBandwidth(i32)
A value failed to match a documented Bandwidth
.
InvalidBitrate(i32)
A value failed to match a documented Bitrate
,
negative values are invalid.
InvalidSignal(i32)
A value failed to match a documented Signal
.
InvalidComplexity(i32)
Complexity was lower than 1 or higher than 10.
InvalidSampleRate(i32)
A value failed to match a documented SampleRate
.
InvalidChannels(i32)
A value failed to match a documented [Channel
].
Opus(ErrorCode)
An error returned from Opus containing an ErrorCode
describing
the cause.
EmptyPacket
Opus is not operating empty packets.
SignalsTooLarge
Opus’ maximum Vec
or slice length of std::i32::MAX
has been
exceeded.
PacketTooLarge
Opus’ maximum Vec
or slice length of std::i32::MAX
has been
exceeded.
MappingExpectedLen(usize)
A Vec
representing a mapping exceeded the expected value.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
impl Copy for Error
impl Eq for Error
impl StructuralPartialEq for Error
Auto Trait Implementations§
impl Freeze for Error
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
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