Enum sameold::UnrecognizedEventCode
source · [−]pub enum UnrecognizedEventCode {
Unrecognized,
WithSignificance(SignificanceLevel),
}Expand description
An unrecognized SAME event code
Even if the complete event code is unknown, the parser may
still be able to extract some meaning from it. Most new
messages end in the
SignificanceLevel. A new
“Derecho Warning” message, with fictitious code “DEW,”
still ends in W for Warning. Your client application
should react to it accordingly as a life-threatening Warning,
even if your parser doesn’t know what it is.
If the code is unknown and can’t be coerced to any of the
SignificanceLevel, then
UnrecognizedEventCode::Unrecognized is returned.
Variants
Unrecognized
A completely unrecognizable event code
WithSignificance(SignificanceLevel)
An unknown event code which does match a significance level
Trait Implementations
sourceimpl Clone for UnrecognizedEventCode
impl Clone for UnrecognizedEventCode
sourcefn clone(&self) -> UnrecognizedEventCode
fn clone(&self) -> UnrecognizedEventCode
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for UnrecognizedEventCode
impl Debug for UnrecognizedEventCode
sourceimpl Display for UnrecognizedEventCode
impl Display for UnrecognizedEventCode
sourceimpl Error for UnrecognizedEventCode
impl Error for UnrecognizedEventCode
1.30.0 · sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
sourcefn backtrace(&self) -> Option<&Backtrace>
fn backtrace(&self) -> Option<&Backtrace>
backtrace)Returns a stack backtrace, if available, of where this error occurred. Read more
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
sourceimpl From<&'_ str> for UnrecognizedEventCode
impl From<&'_ str> for UnrecognizedEventCode
sourceimpl PartialEq<UnrecognizedEventCode> for UnrecognizedEventCode
impl PartialEq<UnrecognizedEventCode> for UnrecognizedEventCode
sourcefn eq(&self, other: &UnrecognizedEventCode) -> bool
fn eq(&self, other: &UnrecognizedEventCode) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &UnrecognizedEventCode) -> bool
fn ne(&self, other: &UnrecognizedEventCode) -> bool
This method tests for !=.
impl Eq for UnrecognizedEventCode
impl StructuralEq for UnrecognizedEventCode
impl StructuralPartialEq for UnrecognizedEventCode
Auto Trait Implementations
impl RefUnwindSafe for UnrecognizedEventCode
impl Send for UnrecognizedEventCode
impl Sync for UnrecognizedEventCode
impl Unpin for UnrecognizedEventCode
impl UnwindSafe for UnrecognizedEventCode
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct self from the equivalent element of its
superset. Read more
fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if self is actually part of its subset T (and can be converted to it).
fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as self.to_subset but without any property checks. Always succeeds.
fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts self to the equivalent element of its superset.