#[non_exhaustive]pub enum PduError {
InvalidHex,
Truncated(&'static str),
Invalid(&'static str),
ReservedMessageType,
Unencodable(char),
TooManyParts,
MissingConcatRef,
}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.
InvalidHex
Input is not an even-length hex string.
Truncated(&'static str)
Data ended inside the named field.
Invalid(&'static str)
The named field holds a value the spec does not allow.
ReservedMessageType
TP-MTI 0b11 (reserved, 23.040 §9.2.3.1).
Unencodable(char)
Encoding: character not representable in the chosen alphabet.
TooManyParts
Encoding: the message needs more than 255 concatenated parts.
MissingConcatRef
Encoding: the message needs concatenation but
SubmitRequest::concat_ref is None.
Trait Implementations§
impl Copy for PduError
impl Eq for PduError
Source§impl Error for PduError
impl Error for PduError
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()
impl StructuralPartialEq for PduError
Auto Trait Implementations§
impl Forget for PduError
impl Freeze for PduError
impl RefUnwindSafe for PduError
impl Send for PduError
impl Sync for PduError
impl Unpin for PduError
impl UnsafeUnpin for PduError
impl UnwindSafe for PduError
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