#[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 VariableHasWrongType {
    #[builder(into)]
    #[serde(rename = "expectedType")]
    expected_type: String,
    #[serde(rename = "variableName")]
    variable_name: super::super::super::super::super::objects::scout::compute::api::VariableName,
}
impl VariableHasWrongType {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new(
        expected_type: impl Into<String>,
        variable_name: super::super::super::super::super::objects::scout::compute::api::VariableName,
    ) -> Self {
        Self::builder().expected_type(expected_type).variable_name(variable_name).build()
    }
    #[inline]
    pub fn expected_type(&self) -> &str {
        &*self.expected_type
    }
    #[inline]
    pub fn variable_name(
        &self,
    ) -> &super::super::super::super::super::objects::scout::compute::api::VariableName {
        &self.variable_name
    }
}
impl conjure_error::ErrorType for VariableHasWrongType {
    #[inline]
    fn code() -> conjure_error::ErrorCode {
        conjure_error::ErrorCode::InvalidArgument
    }
    #[inline]
    fn name() -> &'static str {
        "Compute:VariableHasWrongType"
    }
    #[inline]
    fn safe_args() -> &'static [&'static str] {
        &["expectedType"]
    }
}
