pub enum FixSource {
Precise(StalenessMetadata),
Broadcast(BroadcastReason),
}Expand description
Which ephemeris source produced a SourcedSolution, with its provenance.
A fallback solve never substitutes a source silently: this enum is always present on the result and records both which source was used and how it related to the requested epoch.
This is not PartialEq because its broadcast reason can carry an
SppError, which is not comparable; classify with the is_* accessors or
match on the variant.
Variants§
Precise(StalenessMetadata)
A precise SP3 product produced the fix. The carried StalenessMetadata
distinguishes a precise-exact result
(DegradationKind::Exact,
zero staleness) from a precise-degraded one
(DegradationKind::NearestPrior,
nonzero staleness) and reports the source epoch and staleness.
Broadcast(BroadcastReason)
The broadcast ephemeris path produced the fix because the precise path was
not used. The carried BroadcastReason explains why, so the substitution
is always explicit.
Implementations§
Source§impl FixSource
impl FixSource
Sourcepub fn is_precise(&self) -> bool
pub fn is_precise(&self) -> bool
Whether a precise SP3 product produced the fix (exact or degraded).
Sourcepub fn is_broadcast(&self) -> bool
pub fn is_broadcast(&self) -> bool
Whether the broadcast path produced the fix.
Sourcepub fn is_precise_exact(&self) -> bool
pub fn is_precise_exact(&self) -> bool
Whether a precise product covering the exact epoch produced the fix (no degradation, zero staleness).
Sourcepub fn staleness(&self) -> Option<StalenessMetadata>
pub fn staleness(&self) -> Option<StalenessMetadata>
The staleness metadata of the source that produced the fix: the precise
product’s staleness for a precise fix, or None for a broadcast fix (the
broadcast fix is not backed by a precise product). For the
degraded-then-fell-back case, the staleness of the precise product that was
tried is available via
BroadcastReason::attempted_staleness.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FixSource
impl RefUnwindSafe for FixSource
impl Send for FixSource
impl Sync for FixSource
impl Unpin for FixSource
impl UnsafeUnpin for FixSource
impl UnwindSafe for FixSource
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.