#[non_exhaustive]pub enum StartSpeechSynthesisTaskError {
Show 13 variants
EngineNotSupportedException(EngineNotSupportedException),
InvalidS3BucketException(InvalidS3BucketException),
InvalidS3KeyException(InvalidS3KeyException),
InvalidSampleRateException(InvalidSampleRateException),
InvalidSnsTopicArnException(InvalidSnsTopicArnException),
InvalidSsmlException(InvalidSsmlException),
LanguageNotSupportedException(LanguageNotSupportedException),
LexiconNotFoundException(LexiconNotFoundException),
MarksNotSupportedForFormatException(MarksNotSupportedForFormatException),
ServiceFailureException(ServiceFailureException),
SsmlMarksNotSupportedForTextTypeException(SsmlMarksNotSupportedForTextTypeException),
TextLengthExceededException(TextLengthExceededException),
Unhandled(Unhandled),
}
Expand description
Error type for the StartSpeechSynthesisTaskError
operation.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
EngineNotSupportedException(EngineNotSupportedException)
This engine is not compatible with the voice that you have designated. Choose a new voice that is compatible with the engine or change the engine and restart the operation.
InvalidS3BucketException(InvalidS3BucketException)
The provided Amazon S3 bucket name is invalid. Please check your input with S3 bucket naming requirements and try again.
InvalidS3KeyException(InvalidS3KeyException)
The provided Amazon S3 key prefix is invalid. Please provide a valid S3 object key name.
InvalidSampleRateException(InvalidSampleRateException)
The specified sample rate is not valid.
InvalidSnsTopicArnException(InvalidSnsTopicArnException)
The provided SNS topic ARN is invalid. Please provide a valid SNS topic ARN and try again.
InvalidSsmlException(InvalidSsmlException)
The SSML you provided is invalid. Verify the SSML syntax, spelling of tags and values, and then try again.
LanguageNotSupportedException(LanguageNotSupportedException)
The language specified is not currently supported by Amazon Polly in this capacity.
LexiconNotFoundException(LexiconNotFoundException)
Amazon Polly can't find the specified lexicon. This could be caused by a lexicon that is missing, its name is misspelled or specifying a lexicon that is in a different region.
Verify that the lexicon exists, is in the region (see ListLexicons
) and that you spelled its name is spelled correctly. Then try again.
MarksNotSupportedForFormatException(MarksNotSupportedForFormatException)
Speech marks are not supported for the OutputFormat
selected. Speech marks are only available for content in json
format.
ServiceFailureException(ServiceFailureException)
An unknown condition has caused a service failure.
SsmlMarksNotSupportedForTextTypeException(SsmlMarksNotSupportedForTextTypeException)
SSML speech marks are not supported for plain text-type input.
TextLengthExceededException(TextLengthExceededException)
The value of the "Text" parameter is longer than the accepted limits. For the SynthesizeSpeech
API, the limit for input text is a maximum of 6000 characters total, of which no more than 3000 can be billed characters. For the StartSpeechSynthesisTask
API, the maximum is 200,000 characters, of which no more than 100,000 can be billed characters. SSML tags are not counted as billed characters.
Unhandled(Unhandled)
An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
Implementations§
source§impl StartSpeechSynthesisTaskError
impl StartSpeechSynthesisTaskError
sourcepub fn unhandled(err: impl Into<Box<dyn Error + Send + Sync + 'static>>) -> Self
pub fn unhandled(err: impl Into<Box<dyn Error + Send + Sync + 'static>>) -> Self
Creates the StartSpeechSynthesisTaskError::Unhandled
variant from any error type.
sourcepub fn generic(err: ErrorMetadata) -> Self
pub fn generic(err: ErrorMetadata) -> Self
Creates the StartSpeechSynthesisTaskError::Unhandled
variant from a ::aws_smithy_types::error::ErrorMetadata
.
sourcepub fn meta(&self) -> &ErrorMetadata
pub fn meta(&self) -> &ErrorMetadata
Returns error metadata, which includes the error code, message, request ID, and potentially additional information.
sourcepub fn is_engine_not_supported_exception(&self) -> bool
pub fn is_engine_not_supported_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::EngineNotSupportedException
.
sourcepub fn is_invalid_s3_bucket_exception(&self) -> bool
pub fn is_invalid_s3_bucket_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::InvalidS3BucketException
.
sourcepub fn is_invalid_s3_key_exception(&self) -> bool
pub fn is_invalid_s3_key_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::InvalidS3KeyException
.
sourcepub fn is_invalid_sample_rate_exception(&self) -> bool
pub fn is_invalid_sample_rate_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::InvalidSampleRateException
.
sourcepub fn is_invalid_sns_topic_arn_exception(&self) -> bool
pub fn is_invalid_sns_topic_arn_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::InvalidSnsTopicArnException
.
sourcepub fn is_invalid_ssml_exception(&self) -> bool
pub fn is_invalid_ssml_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::InvalidSsmlException
.
sourcepub fn is_language_not_supported_exception(&self) -> bool
pub fn is_language_not_supported_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::LanguageNotSupportedException
.
sourcepub fn is_lexicon_not_found_exception(&self) -> bool
pub fn is_lexicon_not_found_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::LexiconNotFoundException
.
sourcepub fn is_marks_not_supported_for_format_exception(&self) -> bool
pub fn is_marks_not_supported_for_format_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::MarksNotSupportedForFormatException
.
sourcepub fn is_service_failure_exception(&self) -> bool
pub fn is_service_failure_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::ServiceFailureException
.
sourcepub fn is_ssml_marks_not_supported_for_text_type_exception(&self) -> bool
pub fn is_ssml_marks_not_supported_for_text_type_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::SsmlMarksNotSupportedForTextTypeException
.
sourcepub fn is_text_length_exceeded_exception(&self) -> bool
pub fn is_text_length_exceeded_exception(&self) -> bool
Returns true
if the error kind is StartSpeechSynthesisTaskError::TextLengthExceededException
.
Trait Implementations§
source§impl CreateUnhandledError for StartSpeechSynthesisTaskError
impl CreateUnhandledError for StartSpeechSynthesisTaskError
source§fn create_unhandled_error(
source: Box<dyn Error + Send + Sync + 'static>,
meta: Option<ErrorMetadata>
) -> Self
fn create_unhandled_error( source: Box<dyn Error + Send + Sync + 'static>, meta: Option<ErrorMetadata> ) -> Self
source
and error metadata.source§impl Error for StartSpeechSynthesisTaskError
impl Error for StartSpeechSynthesisTaskError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
source§impl From<StartSpeechSynthesisTaskError> for Error
impl From<StartSpeechSynthesisTaskError> for Error
source§fn from(err: StartSpeechSynthesisTaskError) -> Self
fn from(err: StartSpeechSynthesisTaskError) -> Self
source§impl ProvideErrorMetadata for StartSpeechSynthesisTaskError
impl ProvideErrorMetadata for StartSpeechSynthesisTaskError
source§fn meta(&self) -> &ErrorMetadata
fn meta(&self) -> &ErrorMetadata
source§impl RequestId for StartSpeechSynthesisTaskError
impl RequestId for StartSpeechSynthesisTaskError
source§fn request_id(&self) -> Option<&str>
fn request_id(&self) -> Option<&str>
None
if the service could not be reached.