aws-sdk-forecast 1.101.0

AWS SDK for Amazon Forecast 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 DescribeDatasetOutput {
    /// <p>The Amazon Resource Name (ARN) of the dataset.</p>
    pub dataset_arn: ::std::option::Option<::std::string::String>,
    /// <p>The name of the dataset.</p>
    pub dataset_name: ::std::option::Option<::std::string::String>,
    /// <p>The domain associated with the dataset.</p>
    pub domain: ::std::option::Option<crate::types::Domain>,
    /// <p>The dataset type.</p>
    pub dataset_type: ::std::option::Option<crate::types::DatasetType>,
    /// <p>The frequency of data collection.</p>
    /// <p>Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "M" indicates every month and "30min" indicates every 30 minutes.</p>
    pub data_frequency: ::std::option::Option<::std::string::String>,
    /// <p>An array of <code>SchemaAttribute</code> objects that specify the dataset fields. Each <code>SchemaAttribute</code> specifies the name and data type of a field.</p>
    pub schema: ::std::option::Option<crate::types::Schema>,
    /// <p>The Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.</p>
    pub encryption_config: ::std::option::Option<crate::types::EncryptionConfig>,
    /// <p>The status of the dataset. States include:</p>
    /// <ul>
    /// <li>
    /// <p><code>ACTIVE</code></p></li>
    /// <li>
    /// <p><code>CREATE_PENDING</code>, <code>CREATE_IN_PROGRESS</code>, <code>CREATE_FAILED</code></p></li>
    /// <li>
    /// <p><code>DELETE_PENDING</code>, <code>DELETE_IN_PROGRESS</code>, <code>DELETE_FAILED</code></p></li>
    /// <li>
    /// <p><code>UPDATE_PENDING</code>, <code>UPDATE_IN_PROGRESS</code>, <code>UPDATE_FAILED</code></p></li>
    /// </ul>
    /// <p>The <code>UPDATE</code> states apply while data is imported to the dataset from a call to the <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation and reflect the status of the dataset import job. For example, when the import job status is <code>CREATE_IN_PROGRESS</code>, the status of the dataset is <code>UPDATE_IN_PROGRESS</code>.</p><note>
    /// <p>The <code>Status</code> of the dataset must be <code>ACTIVE</code> before you can import training data.</p>
    /// </note>
    pub status: ::std::option::Option<::std::string::String>,
    /// <p>When the dataset was created.</p>
    pub creation_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>When you create a dataset, <code>LastModificationTime</code> is the same as <code>CreationTime</code>. While data is being imported to the dataset, <code>LastModificationTime</code> is the current time of the <code>DescribeDataset</code> call. After a <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation has finished, <code>LastModificationTime</code> is when the import job completed or failed.</p>
    pub last_modification_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    _request_id: Option<String>,
}
impl DescribeDatasetOutput {
    /// <p>The Amazon Resource Name (ARN) of the dataset.</p>
    pub fn dataset_arn(&self) -> ::std::option::Option<&str> {
        self.dataset_arn.as_deref()
    }
    /// <p>The name of the dataset.</p>
    pub fn dataset_name(&self) -> ::std::option::Option<&str> {
        self.dataset_name.as_deref()
    }
    /// <p>The domain associated with the dataset.</p>
    pub fn domain(&self) -> ::std::option::Option<&crate::types::Domain> {
        self.domain.as_ref()
    }
    /// <p>The dataset type.</p>
    pub fn dataset_type(&self) -> ::std::option::Option<&crate::types::DatasetType> {
        self.dataset_type.as_ref()
    }
    /// <p>The frequency of data collection.</p>
    /// <p>Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "M" indicates every month and "30min" indicates every 30 minutes.</p>
    pub fn data_frequency(&self) -> ::std::option::Option<&str> {
        self.data_frequency.as_deref()
    }
    /// <p>An array of <code>SchemaAttribute</code> objects that specify the dataset fields. Each <code>SchemaAttribute</code> specifies the name and data type of a field.</p>
    pub fn schema(&self) -> ::std::option::Option<&crate::types::Schema> {
        self.schema.as_ref()
    }
    /// <p>The Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.</p>
    pub fn encryption_config(&self) -> ::std::option::Option<&crate::types::EncryptionConfig> {
        self.encryption_config.as_ref()
    }
    /// <p>The status of the dataset. States include:</p>
    /// <ul>
    /// <li>
    /// <p><code>ACTIVE</code></p></li>
    /// <li>
    /// <p><code>CREATE_PENDING</code>, <code>CREATE_IN_PROGRESS</code>, <code>CREATE_FAILED</code></p></li>
    /// <li>
    /// <p><code>DELETE_PENDING</code>, <code>DELETE_IN_PROGRESS</code>, <code>DELETE_FAILED</code></p></li>
    /// <li>
    /// <p><code>UPDATE_PENDING</code>, <code>UPDATE_IN_PROGRESS</code>, <code>UPDATE_FAILED</code></p></li>
    /// </ul>
    /// <p>The <code>UPDATE</code> states apply while data is imported to the dataset from a call to the <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation and reflect the status of the dataset import job. For example, when the import job status is <code>CREATE_IN_PROGRESS</code>, the status of the dataset is <code>UPDATE_IN_PROGRESS</code>.</p><note>
    /// <p>The <code>Status</code> of the dataset must be <code>ACTIVE</code> before you can import training data.</p>
    /// </note>
    pub fn status(&self) -> ::std::option::Option<&str> {
        self.status.as_deref()
    }
    /// <p>When the dataset was created.</p>
    pub fn creation_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.creation_time.as_ref()
    }
    /// <p>When you create a dataset, <code>LastModificationTime</code> is the same as <code>CreationTime</code>. While data is being imported to the dataset, <code>LastModificationTime</code> is the current time of the <code>DescribeDataset</code> call. After a <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation has finished, <code>LastModificationTime</code> is when the import job completed or failed.</p>
    pub fn last_modification_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.last_modification_time.as_ref()
    }
}
impl ::aws_types::request_id::RequestId for DescribeDatasetOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl DescribeDatasetOutput {
    /// Creates a new builder-style object to manufacture [`DescribeDatasetOutput`](crate::operation::describe_dataset::DescribeDatasetOutput).
    pub fn builder() -> crate::operation::describe_dataset::builders::DescribeDatasetOutputBuilder {
        crate::operation::describe_dataset::builders::DescribeDatasetOutputBuilder::default()
    }
}

/// A builder for [`DescribeDatasetOutput`](crate::operation::describe_dataset::DescribeDatasetOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DescribeDatasetOutputBuilder {
    pub(crate) dataset_arn: ::std::option::Option<::std::string::String>,
    pub(crate) dataset_name: ::std::option::Option<::std::string::String>,
    pub(crate) domain: ::std::option::Option<crate::types::Domain>,
    pub(crate) dataset_type: ::std::option::Option<crate::types::DatasetType>,
    pub(crate) data_frequency: ::std::option::Option<::std::string::String>,
    pub(crate) schema: ::std::option::Option<crate::types::Schema>,
    pub(crate) encryption_config: ::std::option::Option<crate::types::EncryptionConfig>,
    pub(crate) status: ::std::option::Option<::std::string::String>,
    pub(crate) creation_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) last_modification_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    _request_id: Option<String>,
}
impl DescribeDatasetOutputBuilder {
    /// <p>The Amazon Resource Name (ARN) of the dataset.</p>
    pub fn dataset_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.dataset_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Resource Name (ARN) of the dataset.</p>
    pub fn set_dataset_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.dataset_arn = input;
        self
    }
    /// <p>The Amazon Resource Name (ARN) of the dataset.</p>
    pub fn get_dataset_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.dataset_arn
    }
    /// <p>The name of the dataset.</p>
    pub fn dataset_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.dataset_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the dataset.</p>
    pub fn set_dataset_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.dataset_name = input;
        self
    }
    /// <p>The name of the dataset.</p>
    pub fn get_dataset_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.dataset_name
    }
    /// <p>The domain associated with the dataset.</p>
    pub fn domain(mut self, input: crate::types::Domain) -> Self {
        self.domain = ::std::option::Option::Some(input);
        self
    }
    /// <p>The domain associated with the dataset.</p>
    pub fn set_domain(mut self, input: ::std::option::Option<crate::types::Domain>) -> Self {
        self.domain = input;
        self
    }
    /// <p>The domain associated with the dataset.</p>
    pub fn get_domain(&self) -> &::std::option::Option<crate::types::Domain> {
        &self.domain
    }
    /// <p>The dataset type.</p>
    pub fn dataset_type(mut self, input: crate::types::DatasetType) -> Self {
        self.dataset_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The dataset type.</p>
    pub fn set_dataset_type(mut self, input: ::std::option::Option<crate::types::DatasetType>) -> Self {
        self.dataset_type = input;
        self
    }
    /// <p>The dataset type.</p>
    pub fn get_dataset_type(&self) -> &::std::option::Option<crate::types::DatasetType> {
        &self.dataset_type
    }
    /// <p>The frequency of data collection.</p>
    /// <p>Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "M" indicates every month and "30min" indicates every 30 minutes.</p>
    pub fn data_frequency(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_frequency = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The frequency of data collection.</p>
    /// <p>Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "M" indicates every month and "30min" indicates every 30 minutes.</p>
    pub fn set_data_frequency(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_frequency = input;
        self
    }
    /// <p>The frequency of data collection.</p>
    /// <p>Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "M" indicates every month and "30min" indicates every 30 minutes.</p>
    pub fn get_data_frequency(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_frequency
    }
    /// <p>An array of <code>SchemaAttribute</code> objects that specify the dataset fields. Each <code>SchemaAttribute</code> specifies the name and data type of a field.</p>
    pub fn schema(mut self, input: crate::types::Schema) -> Self {
        self.schema = ::std::option::Option::Some(input);
        self
    }
    /// <p>An array of <code>SchemaAttribute</code> objects that specify the dataset fields. Each <code>SchemaAttribute</code> specifies the name and data type of a field.</p>
    pub fn set_schema(mut self, input: ::std::option::Option<crate::types::Schema>) -> Self {
        self.schema = input;
        self
    }
    /// <p>An array of <code>SchemaAttribute</code> objects that specify the dataset fields. Each <code>SchemaAttribute</code> specifies the name and data type of a field.</p>
    pub fn get_schema(&self) -> &::std::option::Option<crate::types::Schema> {
        &self.schema
    }
    /// <p>The Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.</p>
    pub fn encryption_config(mut self, input: crate::types::EncryptionConfig) -> Self {
        self.encryption_config = ::std::option::Option::Some(input);
        self
    }
    /// <p>The Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.</p>
    pub fn set_encryption_config(mut self, input: ::std::option::Option<crate::types::EncryptionConfig>) -> Self {
        self.encryption_config = input;
        self
    }
    /// <p>The Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.</p>
    pub fn get_encryption_config(&self) -> &::std::option::Option<crate::types::EncryptionConfig> {
        &self.encryption_config
    }
    /// <p>The status of the dataset. States include:</p>
    /// <ul>
    /// <li>
    /// <p><code>ACTIVE</code></p></li>
    /// <li>
    /// <p><code>CREATE_PENDING</code>, <code>CREATE_IN_PROGRESS</code>, <code>CREATE_FAILED</code></p></li>
    /// <li>
    /// <p><code>DELETE_PENDING</code>, <code>DELETE_IN_PROGRESS</code>, <code>DELETE_FAILED</code></p></li>
    /// <li>
    /// <p><code>UPDATE_PENDING</code>, <code>UPDATE_IN_PROGRESS</code>, <code>UPDATE_FAILED</code></p></li>
    /// </ul>
    /// <p>The <code>UPDATE</code> states apply while data is imported to the dataset from a call to the <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation and reflect the status of the dataset import job. For example, when the import job status is <code>CREATE_IN_PROGRESS</code>, the status of the dataset is <code>UPDATE_IN_PROGRESS</code>.</p><note>
    /// <p>The <code>Status</code> of the dataset must be <code>ACTIVE</code> before you can import training data.</p>
    /// </note>
    pub fn status(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.status = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The status of the dataset. States include:</p>
    /// <ul>
    /// <li>
    /// <p><code>ACTIVE</code></p></li>
    /// <li>
    /// <p><code>CREATE_PENDING</code>, <code>CREATE_IN_PROGRESS</code>, <code>CREATE_FAILED</code></p></li>
    /// <li>
    /// <p><code>DELETE_PENDING</code>, <code>DELETE_IN_PROGRESS</code>, <code>DELETE_FAILED</code></p></li>
    /// <li>
    /// <p><code>UPDATE_PENDING</code>, <code>UPDATE_IN_PROGRESS</code>, <code>UPDATE_FAILED</code></p></li>
    /// </ul>
    /// <p>The <code>UPDATE</code> states apply while data is imported to the dataset from a call to the <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation and reflect the status of the dataset import job. For example, when the import job status is <code>CREATE_IN_PROGRESS</code>, the status of the dataset is <code>UPDATE_IN_PROGRESS</code>.</p><note>
    /// <p>The <code>Status</code> of the dataset must be <code>ACTIVE</code> before you can import training data.</p>
    /// </note>
    pub fn set_status(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.status = input;
        self
    }
    /// <p>The status of the dataset. States include:</p>
    /// <ul>
    /// <li>
    /// <p><code>ACTIVE</code></p></li>
    /// <li>
    /// <p><code>CREATE_PENDING</code>, <code>CREATE_IN_PROGRESS</code>, <code>CREATE_FAILED</code></p></li>
    /// <li>
    /// <p><code>DELETE_PENDING</code>, <code>DELETE_IN_PROGRESS</code>, <code>DELETE_FAILED</code></p></li>
    /// <li>
    /// <p><code>UPDATE_PENDING</code>, <code>UPDATE_IN_PROGRESS</code>, <code>UPDATE_FAILED</code></p></li>
    /// </ul>
    /// <p>The <code>UPDATE</code> states apply while data is imported to the dataset from a call to the <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation and reflect the status of the dataset import job. For example, when the import job status is <code>CREATE_IN_PROGRESS</code>, the status of the dataset is <code>UPDATE_IN_PROGRESS</code>.</p><note>
    /// <p>The <code>Status</code> of the dataset must be <code>ACTIVE</code> before you can import training data.</p>
    /// </note>
    pub fn get_status(&self) -> &::std::option::Option<::std::string::String> {
        &self.status
    }
    /// <p>When the dataset was created.</p>
    pub fn creation_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.creation_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>When the dataset was created.</p>
    pub fn set_creation_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.creation_time = input;
        self
    }
    /// <p>When the dataset was created.</p>
    pub fn get_creation_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.creation_time
    }
    /// <p>When you create a dataset, <code>LastModificationTime</code> is the same as <code>CreationTime</code>. While data is being imported to the dataset, <code>LastModificationTime</code> is the current time of the <code>DescribeDataset</code> call. After a <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation has finished, <code>LastModificationTime</code> is when the import job completed or failed.</p>
    pub fn last_modification_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.last_modification_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>When you create a dataset, <code>LastModificationTime</code> is the same as <code>CreationTime</code>. While data is being imported to the dataset, <code>LastModificationTime</code> is the current time of the <code>DescribeDataset</code> call. After a <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation has finished, <code>LastModificationTime</code> is when the import job completed or failed.</p>
    pub fn set_last_modification_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.last_modification_time = input;
        self
    }
    /// <p>When you create a dataset, <code>LastModificationTime</code> is the same as <code>CreationTime</code>. While data is being imported to the dataset, <code>LastModificationTime</code> is the current time of the <code>DescribeDataset</code> call. After a <a href="https://docs.aws.amazon.com/forecast/latest/dg/API_CreateDatasetImportJob.html">CreateDatasetImportJob</a> operation has finished, <code>LastModificationTime</code> is when the import job completed or failed.</p>
    pub fn get_last_modification_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.last_modification_time
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`DescribeDatasetOutput`](crate::operation::describe_dataset::DescribeDatasetOutput).
    pub fn build(self) -> crate::operation::describe_dataset::DescribeDatasetOutput {
        crate::operation::describe_dataset::DescribeDatasetOutput {
            dataset_arn: self.dataset_arn,
            dataset_name: self.dataset_name,
            domain: self.domain,
            dataset_type: self.dataset_type,
            data_frequency: self.data_frequency,
            schema: self.schema,
            encryption_config: self.encryption_config,
            status: self.status,
            creation_time: self.creation_time,
            last_modification_time: self.last_modification_time,
            _request_id: self._request_id,
        }
    }
}