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§
source§impl Clone for UnrecognizedEventCode
impl Clone for UnrecognizedEventCode
source§fn clone(&self) -> UnrecognizedEventCode
fn clone(&self) -> UnrecognizedEventCode
Returns a copy of the value. Read more
1.0.0 · 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 UnrecognizedEventCode
impl Debug for UnrecognizedEventCode
source§impl Display for UnrecognizedEventCode
impl Display for UnrecognizedEventCode
source§impl Error for UnrecognizedEventCode
impl Error for UnrecognizedEventCode
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
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 From<&str> for UnrecognizedEventCode
impl From<&str> for UnrecognizedEventCode
source§impl PartialEq<UnrecognizedEventCode> for UnrecognizedEventCode
impl PartialEq<UnrecognizedEventCode> for UnrecognizedEventCode
source§fn 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 ==.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§
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere 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.