Struct aws_sdk_translate::client::fluent_builders::TranslateText [−][src]
pub struct TranslateText<C = DynConnector, M = AwsMiddleware, R = Standard> { /* fields omitted */ }
Expand description
Fluent builder constructing a request to TranslateText
.
Translates input text from the source language to the target language. For a list of available languages and language codes, see what-is-languages.
Implementations
impl<C, M, R> TranslateText<C, M, R> where
C: SmithyConnector,
M: SmithyMiddleware<C>,
R: NewRequestPolicy,
impl<C, M, R> TranslateText<C, M, R> where
C: SmithyConnector,
M: SmithyMiddleware<C>,
R: NewRequestPolicy,
pub async fn send(
self
) -> Result<TranslateTextOutput, SdkError<TranslateTextError>> where
R::Policy: SmithyRetryPolicy<TranslateTextInputOperationOutputAlias, TranslateTextOutput, TranslateTextError, TranslateTextInputOperationRetryAlias>,
pub async fn send(
self
) -> Result<TranslateTextOutput, SdkError<TranslateTextError>> where
R::Policy: SmithyRetryPolicy<TranslateTextInputOperationOutputAlias, TranslateTextOutput, TranslateTextError, TranslateTextInputOperationRetryAlias>,
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.
The text to translate. The text string can be a maximum of 5,000 bytes long. Depending on your character set, this may be fewer than 5,000 characters.
The text to translate. The text string can be a maximum of 5,000 bytes long. Depending on your character set, this may be fewer than 5,000 characters.
Appends an item to TerminologyNames
.
To override the contents of this collection use set_terminology_names
.
The name of the terminology list file to be used in the TranslateText request. You can use
1 terminology list at most in a TranslateText
request. Terminology lists can
contain a maximum of 256 terms.
The name of the terminology list file to be used in the TranslateText request. You can use
1 terminology list at most in a TranslateText
request. Terminology lists can
contain a maximum of 256 terms.
The language code for the language of the source text. The language must be a language supported by Amazon Translate. For a list of language codes, see what-is-languages.
To have Amazon Translate determine the source language of your text, you can specify
auto
in the SourceLanguageCode
field. If you specify
auto
, Amazon Translate will call Amazon
Comprehend to determine the source language.
The language code for the language of the source text. The language must be a language supported by Amazon Translate. For a list of language codes, see what-is-languages.
To have Amazon Translate determine the source language of your text, you can specify
auto
in the SourceLanguageCode
field. If you specify
auto
, Amazon Translate will call Amazon
Comprehend to determine the source language.
The language code requested for the language of the target text. The language must be a language supported by Amazon Translate.
The language code requested for the language of the target text. The language must be a language supported by Amazon Translate.
Trait Implementations
Auto Trait Implementations
impl<C = DynConnector, M = AwsMiddleware, R = Standard> !RefUnwindSafe for TranslateText<C, M, R>
impl<C, M, R> Unpin for TranslateText<C, M, R>
impl<C = DynConnector, M = AwsMiddleware, R = Standard> !UnwindSafe for TranslateText<C, M, R>
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more