aws_sdk_kms/
error.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use ::aws_smithy_runtime_api::box_error::BoxError;
3
4/// Error type returned by the client.
5pub type SdkError<E, R = ::aws_smithy_runtime_api::client::orchestrator::HttpResponse> = ::aws_smithy_runtime_api::client::result::SdkError<E, R>;
6pub use ::aws_smithy_runtime_api::client::result::ConnectorError;
7pub use ::aws_smithy_types::error::operation::BuildError;
8
9pub use ::aws_smithy_types::error::display::DisplayErrorContext;
10pub use ::aws_smithy_types::error::metadata::ErrorMetadata;
11pub use ::aws_smithy_types::error::metadata::ProvideErrorMetadata;
12
13/// The given enum value failed to parse since it is not a known value.
14#[derive(Debug)]
15pub struct UnknownVariantError {
16    value: ::std::string::String,
17}
18impl UnknownVariantError {
19    pub(crate) fn new(value: impl ::std::convert::Into<::std::string::String>) -> Self {
20        Self { value: value.into() }
21    }
22}
23impl ::std::fmt::Display for UnknownVariantError {
24    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::result::Result<(), ::std::fmt::Error> {
25        write!(f, "unknown enum variant: '{}'", self.value)
26    }
27}
28impl ::std::error::Error for UnknownVariantError {}
29
30pub(crate) mod sealed_unhandled;