Skip to main content

nominal_api/conjure/objects/scout/compute/api/
forward_fill.rs

1/// At each grid point, carries the most recent prior sample value forward.
2/// The value is held only up to the configured `limit`; grid points with no prior sample
3/// within that window are left empty.
4#[derive(
5    Debug,
6    Clone,
7    conjure_object::serde::Serialize,
8    conjure_object::serde::Deserialize,
9    PartialEq,
10    Eq,
11    PartialOrd,
12    Ord,
13    Hash
14)]
15#[serde(crate = "conjure_object::serde")]
16#[conjure_object::private::staged_builder::staged_builder]
17#[builder(crate = conjure_object::private::staged_builder, update, inline)]
18pub struct ForwardFill {
19    #[builder(custom(type = super::FillLimit, convert = Box::new))]
20    #[serde(rename = "limit")]
21    limit: Box<super::FillLimit>,
22}
23impl ForwardFill {
24    /// Constructs a new instance of the type.
25    #[inline]
26    pub fn new(limit: super::FillLimit) -> Self {
27        Self::builder().limit(limit).build()
28    }
29    #[inline]
30    pub fn limit(&self) -> &super::FillLimit {
31        &*self.limit
32    }
33}