/// This request changes the nominal data type used for one channel in one data source.
/// The operator is expected to be a workspace admin for the workspace containing the data source.
/// The request includes the expected current type so retries and stale caller intent fail visibly.
#[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 ChangeDataTypeRequest {
    #[serde(rename = "dataSourceRid")]
    data_source_rid: conjure_object::ResourceIdentifier,
    #[builder(into)]
    #[serde(rename = "channel")]
    channel: String,
    #[serde(rename = "expectedCurrentType")]
    expected_current_type: super::super::super::super::storage::series::api::NominalDataType,
    #[serde(rename = "newType")]
    new_type: super::super::super::super::storage::series::api::NominalDataType,
}
impl ChangeDataTypeRequest {
    /// Identifies the data source whose channel metadata should be changed.
    #[inline]
    pub fn data_source_rid(&self) -> &conjure_object::ResourceIdentifier {
        &self.data_source_rid
    }
    /// Identifies the channel name within the data source.
    #[inline]
    pub fn channel(&self) -> &str {
        &*self.channel
    }
    /// Provides the exact nominal type the caller expects to be stored in the locator before the change.
    #[inline]
    pub fn expected_current_type(
        &self,
    ) -> &super::super::super::super::storage::series::api::NominalDataType {
        &self.expected_current_type
    }
    /// Provides the exact nominal type future series resolution should use.
    #[inline]
    pub fn new_type(
        &self,
    ) -> &super::super::super::super::storage::series::api::NominalDataType {
        &self.new_type
    }
}
