pub enum BodyBudgetError {
ZeroInput,
OutputTooSmall {
minimum: usize,
actual: usize,
},
}Expand description
Reports which hard body-budget invariant was violated.
Variants§
ZeroInput
The input byte limit was zero.
OutputTooSmall
The output limit cannot contain the complete truncation marker.
Trait Implementations§
Source§impl Clone for BodyBudgetError
impl Clone for BodyBudgetError
Source§fn clone(&self) -> BodyBudgetError
fn clone(&self) -> BodyBudgetError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for BodyBudgetError
Source§impl Debug for BodyBudgetError
impl Debug for BodyBudgetError
Source§impl Display for BodyBudgetError
impl Display for BodyBudgetError
Source§fn fmt(&self, formatter: &mut Formatter<'_>) -> Result
fn fmt(&self, formatter: &mut Formatter<'_>) -> Result
Writes a concise description of the violated budget invariant.
§Parameters
formatter- Destination formatting context.
§Returns
The formatter result from writing the error description.
§Errors
Returns fmt::Error when the destination rejects a write.
impl Eq for BodyBudgetError
Source§impl Error for BodyBudgetError
impl Error for BodyBudgetError
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
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for BodyBudgetError
impl PartialEq for BodyBudgetError
impl StructuralPartialEq for BodyBudgetError
Auto Trait Implementations§
impl Freeze for BodyBudgetError
impl RefUnwindSafe for BodyBudgetError
impl Send for BodyBudgetError
impl Sync for BodyBudgetError
impl Unpin for BodyBudgetError
impl UnsafeUnpin for BodyBudgetError
impl UnwindSafe for BodyBudgetError
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