aws_sdk_lookoutvision/client/create_dataset.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3 /// Constructs a fluent builder for the [`CreateDataset`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder) operation.
4 ///
5 /// - The fluent builder is configurable:
6 /// - [`project_name(impl Into<String>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::project_name) / [`set_project_name(Option<String>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::set_project_name):<br>required: **true**<br><p>The name of the project in which you want to create a dataset.</p><br>
7 /// - [`dataset_type(impl Into<String>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::dataset_type) / [`set_dataset_type(Option<String>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::set_dataset_type):<br>required: **true**<br><p>The type of the dataset. Specify <code>train</code> for a training dataset. Specify <code>test</code> for a test dataset.</p><br>
8 /// - [`dataset_source(DatasetSource)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::dataset_source) / [`set_dataset_source(Option<DatasetSource>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::set_dataset_source):<br>required: **false**<br><p>The location of the manifest file that Amazon Lookout for Vision uses to create the dataset.</p> <p>If you don't specify <code>DatasetSource</code>, an empty dataset is created and the operation synchronously returns. Later, you can add JSON Lines by calling <code>UpdateDatasetEntries</code>.</p> <p>If you specify a value for <code>DataSource</code>, the manifest at the S3 location is validated and used to create the dataset. The call to <code>CreateDataset</code> is asynchronous and might take a while to complete. To find out the current status, Check the value of <code>Status</code> returned in a call to <code>DescribeDataset</code>.</p><br>
9 /// - [`client_token(impl Into<String>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::client_token) / [`set_client_token(Option<String>)`](crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::set_client_token):<br>required: **false**<br><p>ClientToken is an idempotency token that ensures a call to <code>CreateDataset</code> completes only once. You choose the value to pass. For example, An issue might prevent you from getting a response from <code>CreateDataset</code>. In this case, safely retry your call to <code>CreateDataset</code> by using the same <code>ClientToken</code> parameter value.</p> <p>If you don't supply a value for <code>ClientToken</code>, the AWS SDK you are using inserts a value for you. This prevents retries after a network error from making multiple dataset creation requests. You'll need to provide your own value for other use cases.</p> <p>An error occurs if the other input parameters are not the same as in the first request. Using a different value for <code>ClientToken</code> is considered a new call to <code>CreateDataset</code>. An idempotency token is active for 8 hours.</p><br>
10 /// - On success, responds with [`CreateDatasetOutput`](crate::operation::create_dataset::CreateDatasetOutput) with field(s):
11 /// - [`dataset_metadata(Option<DatasetMetadata>)`](crate::operation::create_dataset::CreateDatasetOutput::dataset_metadata): <p>Information about the dataset.</p>
12 /// - On failure, responds with [`SdkError<CreateDatasetError>`](crate::operation::create_dataset::CreateDatasetError)
13 pub fn create_dataset(&self) -> crate::operation::create_dataset::builders::CreateDatasetFluentBuilder {
14 crate::operation::create_dataset::builders::CreateDatasetFluentBuilder::new(self.handle.clone())
15 }
16}