aws-sdk-sagemaker 1.206.0

AWS SDK for Amazon SageMaker Service
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DescribeModelCardInput {
    /// <p>The name or Amazon Resource Name (ARN) of the model card to describe.</p>
    pub model_card_name: ::std::option::Option<::std::string::String>,
    /// <p>The version of the model card to describe. If a version is not provided, then the latest version of the model card is described.</p>
    pub model_card_version: ::std::option::Option<i32>,
    /// <p>Specifies the level of model card data to include in the response. Use this parameter to call <code>DescribeModelCard</code> without requiring <code>kms:Decrypt</code> permission on the customer-managed Amazon Web Services KMS key.</p>
    /// <ul>
    /// <li>
    /// <p><code>AllData</code>: Returns the full model card <code>Content</code>. This option requires <code>kms:Decrypt</code> permission on the customer-managed key, if one is associated with the model card. This is the default.</p></li>
    /// <li>
    /// <p><code>MetadataOnly</code>: Returns the model card with sanitized <code>Content</code> that includes only a small set of unencrypted metadata fields. This option does not require <code>kms:Decrypt</code> permission. For the list of fields preserved in the response, see <code>Content</code>.</p></li>
    /// </ul>
    /// <p>If you don't specify a value, SageMaker returns <code>AllData</code>.</p>
    pub included_data: ::std::option::Option<crate::types::IncludedData>,
}
impl DescribeModelCardInput {
    /// <p>The name or Amazon Resource Name (ARN) of the model card to describe.</p>
    pub fn model_card_name(&self) -> ::std::option::Option<&str> {
        self.model_card_name.as_deref()
    }
    /// <p>The version of the model card to describe. If a version is not provided, then the latest version of the model card is described.</p>
    pub fn model_card_version(&self) -> ::std::option::Option<i32> {
        self.model_card_version
    }
    /// <p>Specifies the level of model card data to include in the response. Use this parameter to call <code>DescribeModelCard</code> without requiring <code>kms:Decrypt</code> permission on the customer-managed Amazon Web Services KMS key.</p>
    /// <ul>
    /// <li>
    /// <p><code>AllData</code>: Returns the full model card <code>Content</code>. This option requires <code>kms:Decrypt</code> permission on the customer-managed key, if one is associated with the model card. This is the default.</p></li>
    /// <li>
    /// <p><code>MetadataOnly</code>: Returns the model card with sanitized <code>Content</code> that includes only a small set of unencrypted metadata fields. This option does not require <code>kms:Decrypt</code> permission. For the list of fields preserved in the response, see <code>Content</code>.</p></li>
    /// </ul>
    /// <p>If you don't specify a value, SageMaker returns <code>AllData</code>.</p>
    pub fn included_data(&self) -> ::std::option::Option<&crate::types::IncludedData> {
        self.included_data.as_ref()
    }
}
impl DescribeModelCardInput {
    /// Creates a new builder-style object to manufacture [`DescribeModelCardInput`](crate::operation::describe_model_card::DescribeModelCardInput).
    pub fn builder() -> crate::operation::describe_model_card::builders::DescribeModelCardInputBuilder {
        crate::operation::describe_model_card::builders::DescribeModelCardInputBuilder::default()
    }
}

/// A builder for [`DescribeModelCardInput`](crate::operation::describe_model_card::DescribeModelCardInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DescribeModelCardInputBuilder {
    pub(crate) model_card_name: ::std::option::Option<::std::string::String>,
    pub(crate) model_card_version: ::std::option::Option<i32>,
    pub(crate) included_data: ::std::option::Option<crate::types::IncludedData>,
}
impl DescribeModelCardInputBuilder {
    /// <p>The name or Amazon Resource Name (ARN) of the model card to describe.</p>
    /// This field is required.
    pub fn model_card_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.model_card_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name or Amazon Resource Name (ARN) of the model card to describe.</p>
    pub fn set_model_card_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.model_card_name = input;
        self
    }
    /// <p>The name or Amazon Resource Name (ARN) of the model card to describe.</p>
    pub fn get_model_card_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.model_card_name
    }
    /// <p>The version of the model card to describe. If a version is not provided, then the latest version of the model card is described.</p>
    pub fn model_card_version(mut self, input: i32) -> Self {
        self.model_card_version = ::std::option::Option::Some(input);
        self
    }
    /// <p>The version of the model card to describe. If a version is not provided, then the latest version of the model card is described.</p>
    pub fn set_model_card_version(mut self, input: ::std::option::Option<i32>) -> Self {
        self.model_card_version = input;
        self
    }
    /// <p>The version of the model card to describe. If a version is not provided, then the latest version of the model card is described.</p>
    pub fn get_model_card_version(&self) -> &::std::option::Option<i32> {
        &self.model_card_version
    }
    /// <p>Specifies the level of model card data to include in the response. Use this parameter to call <code>DescribeModelCard</code> without requiring <code>kms:Decrypt</code> permission on the customer-managed Amazon Web Services KMS key.</p>
    /// <ul>
    /// <li>
    /// <p><code>AllData</code>: Returns the full model card <code>Content</code>. This option requires <code>kms:Decrypt</code> permission on the customer-managed key, if one is associated with the model card. This is the default.</p></li>
    /// <li>
    /// <p><code>MetadataOnly</code>: Returns the model card with sanitized <code>Content</code> that includes only a small set of unencrypted metadata fields. This option does not require <code>kms:Decrypt</code> permission. For the list of fields preserved in the response, see <code>Content</code>.</p></li>
    /// </ul>
    /// <p>If you don't specify a value, SageMaker returns <code>AllData</code>.</p>
    pub fn included_data(mut self, input: crate::types::IncludedData) -> Self {
        self.included_data = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies the level of model card data to include in the response. Use this parameter to call <code>DescribeModelCard</code> without requiring <code>kms:Decrypt</code> permission on the customer-managed Amazon Web Services KMS key.</p>
    /// <ul>
    /// <li>
    /// <p><code>AllData</code>: Returns the full model card <code>Content</code>. This option requires <code>kms:Decrypt</code> permission on the customer-managed key, if one is associated with the model card. This is the default.</p></li>
    /// <li>
    /// <p><code>MetadataOnly</code>: Returns the model card with sanitized <code>Content</code> that includes only a small set of unencrypted metadata fields. This option does not require <code>kms:Decrypt</code> permission. For the list of fields preserved in the response, see <code>Content</code>.</p></li>
    /// </ul>
    /// <p>If you don't specify a value, SageMaker returns <code>AllData</code>.</p>
    pub fn set_included_data(mut self, input: ::std::option::Option<crate::types::IncludedData>) -> Self {
        self.included_data = input;
        self
    }
    /// <p>Specifies the level of model card data to include in the response. Use this parameter to call <code>DescribeModelCard</code> without requiring <code>kms:Decrypt</code> permission on the customer-managed Amazon Web Services KMS key.</p>
    /// <ul>
    /// <li>
    /// <p><code>AllData</code>: Returns the full model card <code>Content</code>. This option requires <code>kms:Decrypt</code> permission on the customer-managed key, if one is associated with the model card. This is the default.</p></li>
    /// <li>
    /// <p><code>MetadataOnly</code>: Returns the model card with sanitized <code>Content</code> that includes only a small set of unencrypted metadata fields. This option does not require <code>kms:Decrypt</code> permission. For the list of fields preserved in the response, see <code>Content</code>.</p></li>
    /// </ul>
    /// <p>If you don't specify a value, SageMaker returns <code>AllData</code>.</p>
    pub fn get_included_data(&self) -> &::std::option::Option<crate::types::IncludedData> {
        &self.included_data
    }
    /// Consumes the builder and constructs a [`DescribeModelCardInput`](crate::operation::describe_model_card::DescribeModelCardInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::describe_model_card::DescribeModelCardInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::describe_model_card::DescribeModelCardInput {
            model_card_name: self.model_card_name,
            model_card_version: self.model_card_version,
            included_data: self.included_data,
        })
    }
}