/// A closed-form curve fit (exponential, logarithmic, or power) of the enclosing target (`y`) against the
/// chosen independent variable (`x`): either sample time (a `time` variable) or another series (a
/// `numeric` variable).
#[derive(
    Debug,
    Clone,
    conjure_object::serde::Serialize,
    conjure_object::serde::Deserialize,
    conjure_object::private::DeriveWith
)]
#[serde(crate = "conjure_object::serde")]
#[derive_with(PartialEq, Eq, PartialOrd, Ord, Hash)]
#[conjure_object::private::staged_builder::staged_builder]
#[builder(crate = conjure_object::private::staged_builder, update, inline)]
pub struct BuiltInCurveFit {
    #[builder(custom(type = super::CurveFitVariable, convert = Box::new))]
    #[serde(rename = "independentVariable")]
    independent_variable: Box<super::CurveFitVariable>,
}
impl BuiltInCurveFit {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new(independent_variable: super::CurveFitVariable) -> Self {
        Self::builder().independent_variable(independent_variable).build()
    }
    /// The `x` axis the target is fit against — either relative sample time or another series.
    #[inline]
    pub fn independent_variable(&self) -> &super::CurveFitVariable {
        &*self.independent_variable
    }
}
