pub struct StationAtmospherePresence {
pub temperature_supplied: bool,
pub pressure_supplied: bool,
}Expand description
Which of a station temperature / pressure pair the caller actually supplied (0.49.0).
A field that is not supplied is resolved by the pre-0.49.0 default-sentinel rule
(resolve_station_temperature / resolve_station_pressure_with_mode): the ICAO
standard at |altitude| > 1 m when the value is the sea-level default, the value itself
otherwise. That makes Self::NEITHER exactly the old behaviour of every presence-blind
API, which is why it is the Default, and makes a supplied field authoritative whatever
its value: a typed 15 °C, 59 °F, 1013.25 hPa or 29.92 inHg at altitude flies as typed.
Pass it to resolve_station_conditions_with_presence, or to one of the
*_with_station_presence twins of the solver, zero, Monte Carlo, lead, hold-curve and
truing entry points.
Fields§
§temperature_supplied: boolThe station temperature was a reading the caller supplied.
pressure_supplied: boolThe station pressure (or the QNH it is reduced from) was a reading the caller supplied.
Implementations§
Source§impl StationAtmospherePresence
impl StationAtmospherePresence
Sourcepub const NEITHER: Self
pub const NEITHER: Self
Neither value was supplied: the pre-0.49.0 default-sentinel rule, bit for bit.
Sourcepub const BOTH: Self
pub const BOTH: Self
Both values were supplied: both fly as given (a declared QNH after its reduction).
Sourcepub const fn new(temperature_supplied: bool, pressure_supplied: bool) -> Self
pub const fn new(temperature_supplied: bool, pressure_supplied: bool) -> Self
Presence from two flags.
Sourcepub const fn from_readings(
temperature: StationReading,
pressure: StationReading,
) -> Self
pub const fn from_readings( temperature: StationReading, pressure: StationReading, ) -> Self
Presence of a temperature reading and a pressure reading.
Trait Implementations§
Source§impl Clone for StationAtmospherePresence
impl Clone for StationAtmospherePresence
Source§fn clone(&self) -> StationAtmospherePresence
fn clone(&self) -> StationAtmospherePresence
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for StationAtmospherePresence
impl Debug for StationAtmospherePresence
Source§impl Default for StationAtmospherePresence
impl Default for StationAtmospherePresence
Source§fn default() -> StationAtmospherePresence
fn default() -> StationAtmospherePresence
Source§impl Hash for StationAtmospherePresence
impl Hash for StationAtmospherePresence
impl Copy for StationAtmospherePresence
impl Eq for StationAtmospherePresence
impl StructuralPartialEq for StationAtmospherePresence
Auto Trait Implementations§
impl Freeze for StationAtmospherePresence
impl RefUnwindSafe for StationAtmospherePresence
impl Send for StationAtmospherePresence
impl Sync for StationAtmospherePresence
impl Unpin for StationAtmospherePresence
impl UnwindSafe for StationAtmospherePresence
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§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>
self from the equivalent element of its
superset. Read more§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).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.