nominal-api 0.1239.0

API bindings for the Nominal platform
Documentation
#[derive(
    Debug,
    Clone,
    conjure_object::serde::Serialize,
    conjure_object::serde::Deserialize,
    PartialEq,
    Eq,
    PartialOrd,
    Ord,
    Hash
)]
#[serde(crate = "conjure_object::serde")]
#[conjure_object::private::staged_builder::staged_builder]
#[builder(crate = conjure_object::private::staged_builder, update, inline)]
pub struct EnumResampleConfiguration {
    #[builder(custom(type = super::DurationConstant, convert = Box::new))]
    #[serde(rename = "interval")]
    interval: Box<super::DurationConstant>,
    #[builder(
        default,
        custom(
            type = impl
            Into<Option<super::EnumResampleInterpolationConfiguration>>,
            convert = |v|v.into().map(Box::new)
        )
    )]
    #[serde(rename = "interpolation", skip_serializing_if = "Option::is_none", default)]
    interpolation: Option<Box<super::EnumResampleInterpolationConfiguration>>,
}
impl EnumResampleConfiguration {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new(interval: super::DurationConstant) -> Self {
        Self::builder().interval(interval).build()
    }
    /// Interval between resampled points
    #[inline]
    pub fn interval(&self) -> &super::DurationConstant {
        &*self.interval
    }
    /// Interpolation strategy to use (defaults to forward fill).
    #[inline]
    pub fn interpolation(
        &self,
    ) -> Option<&super::EnumResampleInterpolationConfiguration> {
        self.interpolation.as_ref().map(|o| &**o)
    }
}