#[non_exhaustive]pub struct AreaBriefingRequest {
pub area: Area,
pub products: Vec<ProductKind>,
pub lookback_hours: Option<u32>,
pub departure_at: Option<DateTime<Utc>>,
}Expand description
A request for a simple area briefing.
Non-exhaustive: future capability parameters (route, altitude band,
aircraft type, product filters) land here — construct with
AreaBriefingRequest::new plus the with_* setters.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.area: AreaArea the briefing covers.
products: Vec<ProductKind>Products to include. Empty means the source’s default set.
lookback_hours: Option<u32>How many hours of history to include where a product has history
(e.g. past METARs). None means the source’s default.
departure_at: Option<DateTime<Utc>>Intended departure time the briefing is for. None means “now”.
Sources that brief relative to a departure instant (Leidos) use
it; observation-oriented sources may ignore it.
Implementations§
Source§impl AreaBriefingRequest
impl AreaBriefingRequest
Sourcepub fn with_products(self, products: Vec<ProductKind>) -> Self
pub fn with_products(self, products: Vec<ProductKind>) -> Self
Restrict to the given product kinds (empty = source default set).
Sourcepub fn with_lookback_hours(self, hours: Option<u32>) -> Self
pub fn with_lookback_hours(self, hours: Option<u32>) -> Self
Include this many hours of history where a product has history.
Sourcepub fn with_departure_at(self, at: Option<DateTime<Utc>>) -> Self
pub fn with_departure_at(self, at: Option<DateTime<Utc>>) -> Self
Anchor the briefing to an intended departure time (ETD).
Trait Implementations§
Source§impl Clone for AreaBriefingRequest
impl Clone for AreaBriefingRequest
Source§fn clone(&self) -> AreaBriefingRequest
fn clone(&self) -> AreaBriefingRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AreaBriefingRequest
impl Debug for AreaBriefingRequest
Source§impl<'de> Deserialize<'de> for AreaBriefingRequest
impl<'de> Deserialize<'de> for AreaBriefingRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for AreaBriefingRequest
impl PartialEq for AreaBriefingRequest
Source§fn eq(&self, other: &AreaBriefingRequest) -> bool
fn eq(&self, other: &AreaBriefingRequest) -> bool
self and other values to be equal, and is used by ==.