#[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 ModuleComputeDefinition {
    #[builder(into)]
    #[serde(rename = "moduleApiName")]
    module_api_name: String,
    #[serde(rename = "moduleRid")]
    module_rid: conjure_object::ResourceIdentifier,
    #[serde(rename = "version")]
    version: super::super::ModuleVersion,
    #[builder(default, list(item(type = super::super::Function)))]
    #[serde(rename = "functions", skip_serializing_if = "Vec::is_empty", default)]
    functions: Vec<super::super::Function>,
}
impl ModuleComputeDefinition {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new(
        module_api_name: impl Into<String>,
        module_rid: conjure_object::ResourceIdentifier,
        version: super::super::ModuleVersion,
    ) -> Self {
        Self::builder()
            .module_api_name(module_api_name)
            .module_rid(module_rid)
            .version(version)
            .build()
    }
    #[inline]
    pub fn module_api_name(&self) -> &str {
        &*self.module_api_name
    }
    #[inline]
    pub fn module_rid(&self) -> &conjure_object::ResourceIdentifier {
        &self.module_rid
    }
    #[inline]
    pub fn version(&self) -> &super::super::ModuleVersion {
        &self.version
    }
    #[inline]
    pub fn functions(&self) -> &[super::super::Function] {
        &*self.functions
    }
}
