pub enum InstructError {
UnknownActuator,
UnknownOperationMode,
FactorOutOfRange(String),
EmptyEnvelope,
NoMatchingEnvelope,
}Expand description
Why an instruction could not be executed.
Variants§
UnknownActuator
The instruction names an actuator this Resource Manager never described.
UnknownOperationMode
The instruction names an operation mode this Resource Manager never described. Refusing is the only safe answer: a mode we cannot name is a mode whose power range we do not know.
FactorOutOfRange(String)
The factor was outside [0, 1], or not a number.
EmptyEnvelope
The instruction carried no envelope element to read a limit from.
NoMatchingEnvelope
No envelope in the instruction covers the commodity the asset consumes.
Trait Implementations§
Source§impl Clone for InstructError
impl Clone for InstructError
Source§fn clone(&self) -> InstructError
fn clone(&self) -> InstructError
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 moreSource§impl Debug for InstructError
impl Debug for InstructError
Source§impl Display for InstructError
impl Display for InstructError
impl Eq for InstructError
Source§impl Error for InstructError
impl Error for InstructError
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 InstructError
impl PartialEq for InstructError
impl StructuralPartialEq for InstructError
Auto Trait Implementations§
impl Freeze for InstructError
impl RefUnwindSafe for InstructError
impl Send for InstructError
impl Sync for InstructError
impl Unpin for InstructError
impl UnsafeUnpin for InstructError
impl UnwindSafe for InstructError
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