Struct aws_sdk_comprehend::client::fluent_builders::ImportModel
source · [−]pub struct ImportModel { /* private fields */ }Expand description
Fluent builder constructing a request to ImportModel.
Creates a new custom model that replicates a source custom model that you import. The source model can be in your AWS account or another one.
If the source model is in another AWS account, then it must have a resource-based policy that authorizes you to import it.
The source model must be in the same AWS region that you're using when you import. You can't import a model that's in a different region.
Implementations
sourceimpl ImportModel
impl ImportModel
sourcepub async fn customize(
self
) -> Result<CustomizableOperation<ImportModel, AwsResponseRetryClassifier>, SdkError<ImportModelError>>
pub async fn customize(
self
) -> Result<CustomizableOperation<ImportModel, AwsResponseRetryClassifier>, SdkError<ImportModelError>>
Consume this builder, creating a customizable operation that can be modified before being sent. The operation’s inner http::Request can be modified as well.
sourcepub async fn send(self) -> Result<ImportModelOutput, SdkError<ImportModelError>>
pub async fn send(self) -> Result<ImportModelOutput, SdkError<ImportModelError>>
Sends the request and returns the response.
If an error occurs, an SdkError will be returned with additional details that
can be matched against.
By default, any retryable failures will be retried twice. Retry behavior is configurable with the RetryConfig, which can be set when configuring the client.
sourcepub fn source_model_arn(self, input: impl Into<String>) -> Self
pub fn source_model_arn(self, input: impl Into<String>) -> Self
The Amazon Resource Name (ARN) of the custom model to import.
sourcepub fn set_source_model_arn(self, input: Option<String>) -> Self
pub fn set_source_model_arn(self, input: Option<String>) -> Self
The Amazon Resource Name (ARN) of the custom model to import.
sourcepub fn model_name(self, input: impl Into<String>) -> Self
pub fn model_name(self, input: impl Into<String>) -> Self
The name to assign to the custom model that is created in Amazon Comprehend by this import.
sourcepub fn set_model_name(self, input: Option<String>) -> Self
pub fn set_model_name(self, input: Option<String>) -> Self
The name to assign to the custom model that is created in Amazon Comprehend by this import.
sourcepub fn version_name(self, input: impl Into<String>) -> Self
pub fn version_name(self, input: impl Into<String>) -> Self
The version name given to the custom model that is created by this import. Version names can have a maximum of 256 characters. Alphanumeric characters, hyphens (-) and underscores (_) are allowed. The version name must be unique among all models with the same classifier name in the account/AWS Region.
sourcepub fn set_version_name(self, input: Option<String>) -> Self
pub fn set_version_name(self, input: Option<String>) -> Self
The version name given to the custom model that is created by this import. Version names can have a maximum of 256 characters. Alphanumeric characters, hyphens (-) and underscores (_) are allowed. The version name must be unique among all models with the same classifier name in the account/AWS Region.
sourcepub fn model_kms_key_id(self, input: impl Into<String>) -> Self
pub fn model_kms_key_id(self, input: impl Into<String>) -> Self
ID for the AWS Key Management Service (KMS) key that Amazon Comprehend uses to encrypt trained custom models. The ModelKmsKeyId can be either of the following formats:
-
KMS Key ID:
"1234abcd-12ab-34cd-56ef-1234567890ab" -
Amazon Resource Name (ARN) of a KMS Key:
"arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab"
sourcepub fn set_model_kms_key_id(self, input: Option<String>) -> Self
pub fn set_model_kms_key_id(self, input: Option<String>) -> Self
ID for the AWS Key Management Service (KMS) key that Amazon Comprehend uses to encrypt trained custom models. The ModelKmsKeyId can be either of the following formats:
-
KMS Key ID:
"1234abcd-12ab-34cd-56ef-1234567890ab" -
Amazon Resource Name (ARN) of a KMS Key:
"arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab"
sourcepub fn data_access_role_arn(self, input: impl Into<String>) -> Self
pub fn data_access_role_arn(self, input: impl Into<String>) -> Self
The Amazon Resource Name (ARN) of the AWS Identity and Management (IAM) role that allows Amazon Comprehend to use Amazon Key Management Service (KMS) to encrypt or decrypt the custom model.
sourcepub fn set_data_access_role_arn(self, input: Option<String>) -> Self
pub fn set_data_access_role_arn(self, input: Option<String>) -> Self
The Amazon Resource Name (ARN) of the AWS Identity and Management (IAM) role that allows Amazon Comprehend to use Amazon Key Management Service (KMS) to encrypt or decrypt the custom model.
Appends an item to Tags.
To override the contents of this collection use set_tags.
Tags to be associated with the custom model that is created by this import. A tag is a key-value pair that adds as a metadata to a resource used by Amazon Comprehend. For example, a tag with "Sales" as the key might be added to a resource to indicate its use by the sales department.
Tags to be associated with the custom model that is created by this import. A tag is a key-value pair that adds as a metadata to a resource used by Amazon Comprehend. For example, a tag with "Sales" as the key might be added to a resource to indicate its use by the sales department.
Trait Implementations
sourceimpl Clone for ImportModel
impl Clone for ImportModel
sourcefn clone(&self) -> ImportModel
fn clone(&self) -> ImportModel
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more