#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UploadMultipartPartError {
pub kind: UploadMultipartPartErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UploadMultipartPartError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UploadMultipartPartErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UploadMultipartPartErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
RequestTimeoutException(crate::error::RequestTimeoutException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for UploadMultipartPartError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UploadMultipartPartErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UploadMultipartPartErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UploadMultipartPartErrorKind::RequestTimeoutException(_inner) => _inner.fmt(f),
UploadMultipartPartErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UploadMultipartPartErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UploadMultipartPartErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UploadMultipartPartError {
fn code(&self) -> Option<&str> {
UploadMultipartPartError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UploadMultipartPartError {
pub fn new(kind: UploadMultipartPartErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: UploadMultipartPartErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UploadMultipartPartErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UploadMultipartPartErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UploadMultipartPartErrorKind::MissingParameterValueException(_)
)
}
pub fn is_request_timeout_exception(&self) -> bool {
matches!(
&self.kind,
UploadMultipartPartErrorKind::RequestTimeoutException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UploadMultipartPartErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UploadMultipartPartErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UploadMultipartPartError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UploadMultipartPartErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UploadMultipartPartErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UploadMultipartPartErrorKind::RequestTimeoutException(_inner) => Some(_inner),
UploadMultipartPartErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UploadMultipartPartErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UploadMultipartPartErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ServiceUnavailableException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl ServiceUnavailableException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl ServiceUnavailableException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for ServiceUnavailableException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ServiceUnavailableException")?;
if let Some(inner_1) = &self.message {
{
write!(f, ": {}", inner_1)?;
}
}
Ok(())
}
}
impl std::error::Error for ServiceUnavailableException {}
pub mod service_unavailable_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::ServiceUnavailableException {
crate::error::ServiceUnavailableException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl ServiceUnavailableException {
pub fn builder() -> crate::error::service_unavailable_exception::Builder {
crate::error::service_unavailable_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ResourceNotFoundException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl ResourceNotFoundException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl ResourceNotFoundException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for ResourceNotFoundException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ResourceNotFoundException")?;
if let Some(inner_2) = &self.message {
{
write!(f, ": {}", inner_2)?;
}
}
Ok(())
}
}
impl std::error::Error for ResourceNotFoundException {}
pub mod resource_not_found_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::ResourceNotFoundException {
crate::error::ResourceNotFoundException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl ResourceNotFoundException {
pub fn builder() -> crate::error::resource_not_found_exception::Builder {
crate::error::resource_not_found_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct RequestTimeoutException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl RequestTimeoutException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl RequestTimeoutException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for RequestTimeoutException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "RequestTimeoutException")?;
if let Some(inner_3) = &self.message {
{
write!(f, ": {}", inner_3)?;
}
}
Ok(())
}
}
impl std::error::Error for RequestTimeoutException {}
pub mod request_timeout_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::RequestTimeoutException {
crate::error::RequestTimeoutException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl RequestTimeoutException {
pub fn builder() -> crate::error::request_timeout_exception::Builder {
crate::error::request_timeout_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct MissingParameterValueException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl MissingParameterValueException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl MissingParameterValueException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for MissingParameterValueException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MissingParameterValueException")?;
if let Some(inner_4) = &self.message {
{
write!(f, ": {}", inner_4)?;
}
}
Ok(())
}
}
impl std::error::Error for MissingParameterValueException {}
pub mod missing_parameter_value_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::MissingParameterValueException {
crate::error::MissingParameterValueException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl MissingParameterValueException {
pub fn builder() -> crate::error::missing_parameter_value_exception::Builder {
crate::error::missing_parameter_value_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InvalidParameterValueException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl InvalidParameterValueException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl InvalidParameterValueException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InvalidParameterValueException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InvalidParameterValueException")?;
if let Some(inner_5) = &self.message {
{
write!(f, ": {}", inner_5)?;
}
}
Ok(())
}
}
impl std::error::Error for InvalidParameterValueException {}
pub mod invalid_parameter_value_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::InvalidParameterValueException {
crate::error::InvalidParameterValueException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl InvalidParameterValueException {
pub fn builder() -> crate::error::invalid_parameter_value_exception::Builder {
crate::error::invalid_parameter_value_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UploadArchiveError {
pub kind: UploadArchiveErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UploadArchiveError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UploadArchiveErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UploadArchiveErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
RequestTimeoutException(crate::error::RequestTimeoutException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for UploadArchiveError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UploadArchiveErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UploadArchiveErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UploadArchiveErrorKind::RequestTimeoutException(_inner) => _inner.fmt(f),
UploadArchiveErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UploadArchiveErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UploadArchiveErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UploadArchiveError {
fn code(&self) -> Option<&str> {
UploadArchiveError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UploadArchiveError {
pub fn new(kind: UploadArchiveErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: UploadArchiveErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UploadArchiveErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UploadArchiveErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UploadArchiveErrorKind::MissingParameterValueException(_)
)
}
pub fn is_request_timeout_exception(&self) -> bool {
matches!(
&self.kind,
UploadArchiveErrorKind::RequestTimeoutException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UploadArchiveErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UploadArchiveErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UploadArchiveError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UploadArchiveErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UploadArchiveErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UploadArchiveErrorKind::RequestTimeoutException(_inner) => Some(_inner),
UploadArchiveErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UploadArchiveErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UploadArchiveErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SetVaultNotificationsError {
pub kind: SetVaultNotificationsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for SetVaultNotificationsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: SetVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SetVaultNotificationsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for SetVaultNotificationsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SetVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
SetVaultNotificationsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
SetVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
SetVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
SetVaultNotificationsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SetVaultNotificationsError {
fn code(&self) -> Option<&str> {
SetVaultNotificationsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl SetVaultNotificationsError {
pub fn new(kind: SetVaultNotificationsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SetVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SetVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultNotificationsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultNotificationsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultNotificationsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultNotificationsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for SetVaultNotificationsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SetVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
SetVaultNotificationsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
SetVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
SetVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
SetVaultNotificationsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SetVaultAccessPolicyError {
pub kind: SetVaultAccessPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for SetVaultAccessPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: SetVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SetVaultAccessPolicyErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for SetVaultAccessPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SetVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
SetVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
SetVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
SetVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
SetVaultAccessPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SetVaultAccessPolicyError {
fn code(&self) -> Option<&str> {
SetVaultAccessPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl SetVaultAccessPolicyError {
pub fn new(kind: SetVaultAccessPolicyErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SetVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SetVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultAccessPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultAccessPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultAccessPolicyErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
SetVaultAccessPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for SetVaultAccessPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SetVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
SetVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => Some(_inner),
SetVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
SetVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
SetVaultAccessPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SetDataRetrievalPolicyError {
pub kind: SetDataRetrievalPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for SetDataRetrievalPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: SetDataRetrievalPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SetDataRetrievalPolicyErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for SetDataRetrievalPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SetDataRetrievalPolicyErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
SetDataRetrievalPolicyErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
SetDataRetrievalPolicyErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
SetDataRetrievalPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SetDataRetrievalPolicyError {
fn code(&self) -> Option<&str> {
SetDataRetrievalPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl SetDataRetrievalPolicyError {
pub fn new(kind: SetDataRetrievalPolicyErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SetDataRetrievalPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SetDataRetrievalPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
SetDataRetrievalPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
SetDataRetrievalPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
SetDataRetrievalPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for SetDataRetrievalPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SetDataRetrievalPolicyErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
SetDataRetrievalPolicyErrorKind::MissingParameterValueException(_inner) => Some(_inner),
SetDataRetrievalPolicyErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
SetDataRetrievalPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct RemoveTagsFromVaultError {
pub kind: RemoveTagsFromVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for RemoveTagsFromVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: RemoveTagsFromVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum RemoveTagsFromVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for RemoveTagsFromVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
RemoveTagsFromVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
RemoveTagsFromVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
RemoveTagsFromVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
RemoveTagsFromVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
RemoveTagsFromVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for RemoveTagsFromVaultError {
fn code(&self) -> Option<&str> {
RemoveTagsFromVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl RemoveTagsFromVaultError {
pub fn new(kind: RemoveTagsFromVaultErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: RemoveTagsFromVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: RemoveTagsFromVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
RemoveTagsFromVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
RemoveTagsFromVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
RemoveTagsFromVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
RemoveTagsFromVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for RemoveTagsFromVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
RemoveTagsFromVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
RemoveTagsFromVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
RemoveTagsFromVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
RemoveTagsFromVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
RemoveTagsFromVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PurchaseProvisionedCapacityError {
pub kind: PurchaseProvisionedCapacityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for PurchaseProvisionedCapacityError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: PurchaseProvisionedCapacityErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PurchaseProvisionedCapacityErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
LimitExceededException(crate::error::LimitExceededException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for PurchaseProvisionedCapacityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PurchaseProvisionedCapacityErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
PurchaseProvisionedCapacityErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
PurchaseProvisionedCapacityErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
PurchaseProvisionedCapacityErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
PurchaseProvisionedCapacityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PurchaseProvisionedCapacityError {
fn code(&self) -> Option<&str> {
PurchaseProvisionedCapacityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl PurchaseProvisionedCapacityError {
pub fn new(kind: PurchaseProvisionedCapacityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: PurchaseProvisionedCapacityErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PurchaseProvisionedCapacityErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
PurchaseProvisionedCapacityErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
PurchaseProvisionedCapacityErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
PurchaseProvisionedCapacityErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
PurchaseProvisionedCapacityErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for PurchaseProvisionedCapacityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PurchaseProvisionedCapacityErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
PurchaseProvisionedCapacityErrorKind::LimitExceededException(_inner) => Some(_inner),
PurchaseProvisionedCapacityErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
PurchaseProvisionedCapacityErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
PurchaseProvisionedCapacityErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct LimitExceededException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl LimitExceededException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl LimitExceededException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for LimitExceededException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "LimitExceededException")?;
if let Some(inner_6) = &self.message {
{
write!(f, ": {}", inner_6)?;
}
}
Ok(())
}
}
impl std::error::Error for LimitExceededException {}
pub mod limit_exceeded_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::LimitExceededException {
crate::error::LimitExceededException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl LimitExceededException {
pub fn builder() -> crate::error::limit_exceeded_exception::Builder {
crate::error::limit_exceeded_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListVaultsError {
pub kind: ListVaultsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListVaultsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListVaultsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListVaultsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListVaultsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListVaultsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListVaultsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListVaultsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListVaultsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListVaultsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListVaultsError {
fn code(&self) -> Option<&str> {
ListVaultsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListVaultsError {
pub fn new(kind: ListVaultsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListVaultsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListVaultsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListVaultsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListVaultsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListVaultsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListVaultsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListVaultsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListVaultsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListVaultsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListVaultsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListVaultsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListVaultsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListTagsForVaultError {
pub kind: ListTagsForVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListTagsForVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListTagsForVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListTagsForVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListTagsForVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListTagsForVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListTagsForVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListTagsForVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListTagsForVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListTagsForVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListTagsForVaultError {
fn code(&self) -> Option<&str> {
ListTagsForVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListTagsForVaultError {
pub fn new(kind: ListTagsForVaultErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListTagsForVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListTagsForVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsForVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsForVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsForVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsForVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListTagsForVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListTagsForVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListTagsForVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListTagsForVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListTagsForVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListTagsForVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListProvisionedCapacityError {
pub kind: ListProvisionedCapacityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListProvisionedCapacityError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListProvisionedCapacityErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListProvisionedCapacityErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListProvisionedCapacityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListProvisionedCapacityErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListProvisionedCapacityErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ListProvisionedCapacityErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListProvisionedCapacityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListProvisionedCapacityError {
fn code(&self) -> Option<&str> {
ListProvisionedCapacityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListProvisionedCapacityError {
pub fn new(kind: ListProvisionedCapacityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListProvisionedCapacityErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListProvisionedCapacityErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListProvisionedCapacityErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListProvisionedCapacityErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListProvisionedCapacityErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListProvisionedCapacityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListProvisionedCapacityErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
ListProvisionedCapacityErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
ListProvisionedCapacityErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListProvisionedCapacityErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListPartsError {
pub kind: ListPartsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListPartsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListPartsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListPartsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListPartsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListPartsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListPartsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListPartsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListPartsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListPartsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListPartsError {
fn code(&self) -> Option<&str> {
ListPartsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListPartsError {
pub fn new(kind: ListPartsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListPartsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListPartsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListPartsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListPartsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, ListPartsErrorKind::ResourceNotFoundException(_))
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListPartsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListPartsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListPartsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListPartsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListPartsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListPartsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListPartsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListMultipartUploadsError {
pub kind: ListMultipartUploadsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListMultipartUploadsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListMultipartUploadsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListMultipartUploadsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListMultipartUploadsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListMultipartUploadsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListMultipartUploadsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListMultipartUploadsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListMultipartUploadsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListMultipartUploadsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListMultipartUploadsError {
fn code(&self) -> Option<&str> {
ListMultipartUploadsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListMultipartUploadsError {
pub fn new(kind: ListMultipartUploadsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListMultipartUploadsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListMultipartUploadsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListMultipartUploadsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListMultipartUploadsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListMultipartUploadsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListMultipartUploadsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListMultipartUploadsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListMultipartUploadsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListMultipartUploadsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListMultipartUploadsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListMultipartUploadsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListMultipartUploadsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListJobsError {
pub kind: ListJobsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListJobsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListJobsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListJobsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListJobsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListJobsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListJobsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListJobsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListJobsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListJobsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListJobsError {
fn code(&self) -> Option<&str> {
ListJobsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListJobsError {
pub fn new(kind: ListJobsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListJobsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListJobsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListJobsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListJobsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, ListJobsErrorKind::ResourceNotFoundException(_))
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListJobsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListJobsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListJobsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListJobsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListJobsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListJobsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListJobsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct InitiateVaultLockError {
pub kind: InitiateVaultLockErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for InitiateVaultLockError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: InitiateVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum InitiateVaultLockErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for InitiateVaultLockError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
InitiateVaultLockErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
InitiateVaultLockErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
InitiateVaultLockErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
InitiateVaultLockErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
InitiateVaultLockErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for InitiateVaultLockError {
fn code(&self) -> Option<&str> {
InitiateVaultLockError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl InitiateVaultLockError {
pub fn new(kind: InitiateVaultLockErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: InitiateVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: InitiateVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
InitiateVaultLockErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
InitiateVaultLockErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
InitiateVaultLockErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
InitiateVaultLockErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for InitiateVaultLockError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
InitiateVaultLockErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
InitiateVaultLockErrorKind::MissingParameterValueException(_inner) => Some(_inner),
InitiateVaultLockErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
InitiateVaultLockErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
InitiateVaultLockErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct InitiateMultipartUploadError {
pub kind: InitiateMultipartUploadErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for InitiateMultipartUploadError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: InitiateMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum InitiateMultipartUploadErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for InitiateMultipartUploadError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
InitiateMultipartUploadErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
InitiateMultipartUploadErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
InitiateMultipartUploadErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
InitiateMultipartUploadErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
InitiateMultipartUploadErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for InitiateMultipartUploadError {
fn code(&self) -> Option<&str> {
InitiateMultipartUploadError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl InitiateMultipartUploadError {
pub fn new(kind: InitiateMultipartUploadErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: InitiateMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: InitiateMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
InitiateMultipartUploadErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
InitiateMultipartUploadErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
InitiateMultipartUploadErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
InitiateMultipartUploadErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for InitiateMultipartUploadError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
InitiateMultipartUploadErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
InitiateMultipartUploadErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
InitiateMultipartUploadErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
InitiateMultipartUploadErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
InitiateMultipartUploadErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct InitiateJobError {
pub kind: InitiateJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for InitiateJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: InitiateJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum InitiateJobErrorKind {
InsufficientCapacityException(crate::error::InsufficientCapacityException),
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
PolicyEnforcedException(crate::error::PolicyEnforcedException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for InitiateJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
InitiateJobErrorKind::InsufficientCapacityException(_inner) => _inner.fmt(f),
InitiateJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
InitiateJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
InitiateJobErrorKind::PolicyEnforcedException(_inner) => _inner.fmt(f),
InitiateJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
InitiateJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
InitiateJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for InitiateJobError {
fn code(&self) -> Option<&str> {
InitiateJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl InitiateJobError {
pub fn new(kind: InitiateJobErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: InitiateJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: InitiateJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_insufficient_capacity_exception(&self) -> bool {
matches!(
&self.kind,
InitiateJobErrorKind::InsufficientCapacityException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
InitiateJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
InitiateJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_policy_enforced_exception(&self) -> bool {
matches!(&self.kind, InitiateJobErrorKind::PolicyEnforcedException(_))
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
InitiateJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
InitiateJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for InitiateJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
InitiateJobErrorKind::InsufficientCapacityException(_inner) => Some(_inner),
InitiateJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
InitiateJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
InitiateJobErrorKind::PolicyEnforcedException(_inner) => Some(_inner),
InitiateJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
InitiateJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
InitiateJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PolicyEnforcedException {
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl PolicyEnforcedException {
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl PolicyEnforcedException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for PolicyEnforcedException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "PolicyEnforcedException")?;
if let Some(inner_7) = &self.message {
{
write!(f, ": {}", inner_7)?;
}
}
Ok(())
}
}
impl std::error::Error for PolicyEnforcedException {}
pub mod policy_enforced_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::PolicyEnforcedException {
crate::error::PolicyEnforcedException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl PolicyEnforcedException {
pub fn builder() -> crate::error::policy_enforced_exception::Builder {
crate::error::policy_enforced_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InsufficientCapacityException {
#[allow(missing_docs)] #[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[allow(missing_docs)] #[doc(hidden)]
pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl InsufficientCapacityException {
#[allow(missing_docs)] pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
}
impl InsufficientCapacityException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InsufficientCapacityException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InsufficientCapacityException")?;
if let Some(inner_8) = &self.message {
{
write!(f, ": {}", inner_8)?;
}
}
Ok(())
}
}
impl std::error::Error for InsufficientCapacityException {}
pub mod insufficient_capacity_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
#[allow(missing_docs)] pub fn r#type(mut self, input: impl Into<std::string::String>) -> Self {
self.r#type = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_type(mut self, input: std::option::Option<std::string::String>) -> Self {
self.r#type = input;
self
}
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::InsufficientCapacityException {
crate::error::InsufficientCapacityException {
r#type: self.r#type,
code: self.code,
message: self.message,
}
}
}
}
impl InsufficientCapacityException {
pub fn builder() -> crate::error::insufficient_capacity_exception::Builder {
crate::error::insufficient_capacity_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetVaultNotificationsError {
pub kind: GetVaultNotificationsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetVaultNotificationsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetVaultNotificationsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetVaultNotificationsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetVaultNotificationsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetVaultNotificationsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetVaultNotificationsError {
fn code(&self) -> Option<&str> {
GetVaultNotificationsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetVaultNotificationsError {
pub fn new(kind: GetVaultNotificationsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultNotificationsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultNotificationsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultNotificationsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultNotificationsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetVaultNotificationsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetVaultNotificationsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetVaultNotificationsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetVaultLockError {
pub kind: GetVaultLockErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetVaultLockError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetVaultLockErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetVaultLockError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetVaultLockErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetVaultLockErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetVaultLockErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetVaultLockErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetVaultLockErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetVaultLockError {
fn code(&self) -> Option<&str> {
GetVaultLockError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetVaultLockError {
pub fn new(kind: GetVaultLockErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultLockErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultLockErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultLockErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultLockErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetVaultLockError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetVaultLockErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetVaultLockErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetVaultLockErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetVaultLockErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetVaultLockErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetVaultAccessPolicyError {
pub kind: GetVaultAccessPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetVaultAccessPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetVaultAccessPolicyErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetVaultAccessPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetVaultAccessPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetVaultAccessPolicyError {
fn code(&self) -> Option<&str> {
GetVaultAccessPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetVaultAccessPolicyError {
pub fn new(kind: GetVaultAccessPolicyErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultAccessPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultAccessPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultAccessPolicyErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetVaultAccessPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetVaultAccessPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetVaultAccessPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetJobOutputError {
pub kind: GetJobOutputErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetJobOutputError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetJobOutputErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetJobOutputErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetJobOutputError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetJobOutputErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetJobOutputErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetJobOutputErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetJobOutputErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetJobOutputErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetJobOutputError {
fn code(&self) -> Option<&str> {
GetJobOutputError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetJobOutputError {
pub fn new(kind: GetJobOutputErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetJobOutputErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetJobOutputErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetJobOutputErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetJobOutputErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetJobOutputErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetJobOutputErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetJobOutputError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetJobOutputErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetJobOutputErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetJobOutputErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetJobOutputErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetJobOutputErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetDataRetrievalPolicyError {
pub kind: GetDataRetrievalPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetDataRetrievalPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetDataRetrievalPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetDataRetrievalPolicyErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetDataRetrievalPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetDataRetrievalPolicyErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
GetDataRetrievalPolicyErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
GetDataRetrievalPolicyErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetDataRetrievalPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetDataRetrievalPolicyError {
fn code(&self) -> Option<&str> {
GetDataRetrievalPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetDataRetrievalPolicyError {
pub fn new(kind: GetDataRetrievalPolicyErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetDataRetrievalPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetDataRetrievalPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetDataRetrievalPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetDataRetrievalPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetDataRetrievalPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetDataRetrievalPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetDataRetrievalPolicyErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetDataRetrievalPolicyErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetDataRetrievalPolicyErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetDataRetrievalPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeVaultError {
pub kind: DescribeVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DescribeVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeVaultError {
fn code(&self) -> Option<&str> {
DescribeVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeVaultError {
pub fn new(kind: DescribeVaultErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: DescribeVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeJobError {
pub kind: DescribeJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeJobErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DescribeJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeJobError {
fn code(&self) -> Option<&str> {
DescribeJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeJobError {
pub fn new(kind: DescribeJobErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: DescribeJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteVaultNotificationsError {
pub kind: DeleteVaultNotificationsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteVaultNotificationsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteVaultNotificationsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteVaultNotificationsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteVaultNotificationsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteVaultNotificationsError {
fn code(&self) -> Option<&str> {
DeleteVaultNotificationsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteVaultNotificationsError {
pub fn new(kind: DeleteVaultNotificationsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: DeleteVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultNotificationsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultNotificationsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultNotificationsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultNotificationsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteVaultNotificationsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DeleteVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DeleteVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteVaultNotificationsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteVaultAccessPolicyError {
pub kind: DeleteVaultAccessPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteVaultAccessPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteVaultAccessPolicyErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteVaultAccessPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteVaultAccessPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteVaultAccessPolicyError {
fn code(&self) -> Option<&str> {
DeleteVaultAccessPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteVaultAccessPolicyError {
pub fn new(kind: DeleteVaultAccessPolicyErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: DeleteVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultAccessPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultAccessPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultAccessPolicyErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultAccessPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteVaultAccessPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DeleteVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DeleteVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteVaultAccessPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteVaultError {
pub kind: DeleteVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteVaultError {
fn code(&self) -> Option<&str> {
DeleteVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteVaultError {
pub fn new(kind: DeleteVaultErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: DeleteVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteArchiveError {
pub kind: DeleteArchiveErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteArchiveError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteArchiveErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteArchiveErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteArchiveError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteArchiveErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteArchiveErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteArchiveErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteArchiveErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteArchiveErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteArchiveError {
fn code(&self) -> Option<&str> {
DeleteArchiveError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteArchiveError {
pub fn new(kind: DeleteArchiveErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: DeleteArchiveErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteArchiveErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteArchiveErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteArchiveErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteArchiveErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteArchiveErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteArchiveError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteArchiveErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteArchiveErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteArchiveErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteArchiveErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteArchiveErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateVaultError {
pub kind: CreateVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
LimitExceededException(crate::error::LimitExceededException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for CreateVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateVaultErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateVaultError {
fn code(&self) -> Option<&str> {
CreateVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateVaultError {
pub fn new(kind: CreateVaultErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: CreateVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(&self.kind, CreateVaultErrorKind::LimitExceededException(_))
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateVaultErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CompleteVaultLockError {
pub kind: CompleteVaultLockErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CompleteVaultLockError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CompleteVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CompleteVaultLockErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for CompleteVaultLockError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CompleteVaultLockErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CompleteVaultLockErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CompleteVaultLockErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
CompleteVaultLockErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CompleteVaultLockErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CompleteVaultLockError {
fn code(&self) -> Option<&str> {
CompleteVaultLockError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CompleteVaultLockError {
pub fn new(kind: CompleteVaultLockErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: CompleteVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CompleteVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CompleteVaultLockErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CompleteVaultLockErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
CompleteVaultLockErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CompleteVaultLockErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CompleteVaultLockError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CompleteVaultLockErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CompleteVaultLockErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CompleteVaultLockErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
CompleteVaultLockErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CompleteVaultLockErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CompleteMultipartUploadError {
pub kind: CompleteMultipartUploadErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CompleteMultipartUploadError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CompleteMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CompleteMultipartUploadErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for CompleteMultipartUploadError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CompleteMultipartUploadErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
CompleteMultipartUploadErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
CompleteMultipartUploadErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
CompleteMultipartUploadErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CompleteMultipartUploadErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CompleteMultipartUploadError {
fn code(&self) -> Option<&str> {
CompleteMultipartUploadError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CompleteMultipartUploadError {
pub fn new(kind: CompleteMultipartUploadErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: CompleteMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CompleteMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CompleteMultipartUploadErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CompleteMultipartUploadErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
CompleteMultipartUploadErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CompleteMultipartUploadErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CompleteMultipartUploadError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CompleteMultipartUploadErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
CompleteMultipartUploadErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
CompleteMultipartUploadErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
CompleteMultipartUploadErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CompleteMultipartUploadErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct AddTagsToVaultError {
pub kind: AddTagsToVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for AddTagsToVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: AddTagsToVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum AddTagsToVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
LimitExceededException(crate::error::LimitExceededException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for AddTagsToVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
AddTagsToVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
AddTagsToVaultErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
AddTagsToVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
AddTagsToVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
AddTagsToVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
AddTagsToVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for AddTagsToVaultError {
fn code(&self) -> Option<&str> {
AddTagsToVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl AddTagsToVaultError {
pub fn new(kind: AddTagsToVaultErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: AddTagsToVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: AddTagsToVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
AddTagsToVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
AddTagsToVaultErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
AddTagsToVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
AddTagsToVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
AddTagsToVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for AddTagsToVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
AddTagsToVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
AddTagsToVaultErrorKind::LimitExceededException(_inner) => Some(_inner),
AddTagsToVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
AddTagsToVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
AddTagsToVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
AddTagsToVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct AbortVaultLockError {
pub kind: AbortVaultLockErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for AbortVaultLockError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: AbortVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum AbortVaultLockErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for AbortVaultLockError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
AbortVaultLockErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
AbortVaultLockErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
AbortVaultLockErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
AbortVaultLockErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
AbortVaultLockErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for AbortVaultLockError {
fn code(&self) -> Option<&str> {
AbortVaultLockError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl AbortVaultLockError {
pub fn new(kind: AbortVaultLockErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: AbortVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: AbortVaultLockErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
AbortVaultLockErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
AbortVaultLockErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
AbortVaultLockErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
AbortVaultLockErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for AbortVaultLockError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
AbortVaultLockErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
AbortVaultLockErrorKind::MissingParameterValueException(_inner) => Some(_inner),
AbortVaultLockErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
AbortVaultLockErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
AbortVaultLockErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct AbortMultipartUploadError {
pub kind: AbortMultipartUploadErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for AbortMultipartUploadError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: AbortMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum AbortMultipartUploadErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for AbortMultipartUploadError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
AbortMultipartUploadErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
AbortMultipartUploadErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
AbortMultipartUploadErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
AbortMultipartUploadErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
AbortMultipartUploadErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for AbortMultipartUploadError {
fn code(&self) -> Option<&str> {
AbortMultipartUploadError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl AbortMultipartUploadError {
pub fn new(kind: AbortMultipartUploadErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: AbortMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: AbortMultipartUploadErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
AbortMultipartUploadErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
AbortMultipartUploadErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
AbortMultipartUploadErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
AbortMultipartUploadErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for AbortMultipartUploadError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
AbortMultipartUploadErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
AbortMultipartUploadErrorKind::MissingParameterValueException(_inner) => Some(_inner),
AbortMultipartUploadErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
AbortMultipartUploadErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
AbortMultipartUploadErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[derive(Debug)]
pub struct Unhandled {
source: Box<dyn std::error::Error + Send + Sync + 'static>,
}
impl Unhandled {
#[allow(unused)]
pub(crate) fn new(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self { source }
}
}
impl std::fmt::Display for Unhandled {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
write!(f, "unhandled error")
}
}
impl std::error::Error for Unhandled {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
Some(self.source.as_ref() as _)
}
}