#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateReportPlanError {
pub kind: UpdateReportPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateReportPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateReportPlanErrorKind {
ConflictException(crate::error::ConflictException),
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 UpdateReportPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateReportPlanErrorKind::ConflictException(_inner) => _inner.fmt(f),
UpdateReportPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UpdateReportPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UpdateReportPlanErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UpdateReportPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UpdateReportPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateReportPlanError {
fn code(&self) -> Option<&str> {
UpdateReportPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateReportPlanError {
pub fn new(kind: UpdateReportPlanErrorKind, 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: UpdateReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateReportPlanErrorKind::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_conflict_exception(&self) -> bool {
matches!(&self.kind, UpdateReportPlanErrorKind::ConflictException(_))
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateReportPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateReportPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UpdateReportPlanErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UpdateReportPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UpdateReportPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateReportPlanErrorKind::ConflictException(_inner) => Some(_inner),
UpdateReportPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UpdateReportPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UpdateReportPlanErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UpdateReportPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UpdateReportPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ServiceUnavailableException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl ServiceUnavailableException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.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) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::ServiceUnavailableException {
crate::error::ServiceUnavailableException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
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 {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl ResourceNotFoundException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.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) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::ResourceNotFoundException {
crate::error::ResourceNotFoundException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
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 MissingParameterValueException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl MissingParameterValueException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.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_3) = &self.message {
{
write!(f, ": {}", inner_3)?;
}
}
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) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::MissingParameterValueException {
crate::error::MissingParameterValueException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
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 {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl InvalidParameterValueException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.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_4) = &self.message {
{
write!(f, ": {}", inner_4)?;
}
}
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) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::InvalidParameterValueException {
crate::error::InvalidParameterValueException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl InvalidParameterValueException {
pub fn builder() -> crate::error::invalid_parameter_value_exception::Builder {
crate::error::invalid_parameter_value_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ConflictException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl ConflictException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.as_deref()
}
}
impl ConflictException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for ConflictException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ConflictException")?;
if let Some(inner_5) = &self.message {
{
write!(f, ": {}", inner_5)?;
}
}
Ok(())
}
}
impl std::error::Error for ConflictException {}
pub mod conflict_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::ConflictException {
crate::error::ConflictException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl ConflictException {
pub fn builder() -> crate::error::conflict_exception::Builder {
crate::error::conflict_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateRegionSettingsError {
pub kind: UpdateRegionSettingsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateRegionSettingsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateRegionSettingsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateRegionSettingsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for UpdateRegionSettingsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateRegionSettingsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UpdateRegionSettingsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UpdateRegionSettingsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UpdateRegionSettingsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateRegionSettingsError {
fn code(&self) -> Option<&str> {
UpdateRegionSettingsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateRegionSettingsError {
pub fn new(kind: UpdateRegionSettingsErrorKind, 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: UpdateRegionSettingsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateRegionSettingsErrorKind::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,
UpdateRegionSettingsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateRegionSettingsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UpdateRegionSettingsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UpdateRegionSettingsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateRegionSettingsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UpdateRegionSettingsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UpdateRegionSettingsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UpdateRegionSettingsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateRecoveryPointLifecycleError {
pub kind: UpdateRecoveryPointLifecycleErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateRecoveryPointLifecycleError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateRecoveryPointLifecycleErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateRecoveryPointLifecycleErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for UpdateRecoveryPointLifecycleError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateRecoveryPointLifecycleErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
UpdateRecoveryPointLifecycleErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
UpdateRecoveryPointLifecycleErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
UpdateRecoveryPointLifecycleErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
UpdateRecoveryPointLifecycleErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
UpdateRecoveryPointLifecycleErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateRecoveryPointLifecycleError {
fn code(&self) -> Option<&str> {
UpdateRecoveryPointLifecycleError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateRecoveryPointLifecycleError {
pub fn new(kind: UpdateRecoveryPointLifecycleErrorKind, 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: UpdateRecoveryPointLifecycleErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateRecoveryPointLifecycleErrorKind::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,
UpdateRecoveryPointLifecycleErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
UpdateRecoveryPointLifecycleErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateRecoveryPointLifecycleErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UpdateRecoveryPointLifecycleErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UpdateRecoveryPointLifecycleErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UpdateRecoveryPointLifecycleError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateRecoveryPointLifecycleErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
UpdateRecoveryPointLifecycleErrorKind::InvalidRequestException(_inner) => Some(_inner),
UpdateRecoveryPointLifecycleErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
UpdateRecoveryPointLifecycleErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
UpdateRecoveryPointLifecycleErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
UpdateRecoveryPointLifecycleErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InvalidRequestException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl InvalidRequestException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.as_deref()
}
}
impl InvalidRequestException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InvalidRequestException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InvalidRequestException")?;
if let Some(inner_6) = &self.message {
{
write!(f, ": {}", inner_6)?;
}
}
Ok(())
}
}
impl std::error::Error for InvalidRequestException {}
pub mod invalid_request_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::InvalidRequestException {
crate::error::InvalidRequestException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl InvalidRequestException {
pub fn builder() -> crate::error::invalid_request_exception::Builder {
crate::error::invalid_request_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateGlobalSettingsError {
pub kind: UpdateGlobalSettingsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateGlobalSettingsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateGlobalSettingsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateGlobalSettingsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for UpdateGlobalSettingsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateGlobalSettingsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UpdateGlobalSettingsErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
UpdateGlobalSettingsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UpdateGlobalSettingsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UpdateGlobalSettingsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateGlobalSettingsError {
fn code(&self) -> Option<&str> {
UpdateGlobalSettingsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateGlobalSettingsError {
pub fn new(kind: UpdateGlobalSettingsErrorKind, 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: UpdateGlobalSettingsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateGlobalSettingsErrorKind::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,
UpdateGlobalSettingsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
UpdateGlobalSettingsErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateGlobalSettingsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UpdateGlobalSettingsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UpdateGlobalSettingsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateGlobalSettingsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UpdateGlobalSettingsErrorKind::InvalidRequestException(_inner) => Some(_inner),
UpdateGlobalSettingsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UpdateGlobalSettingsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UpdateGlobalSettingsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateFrameworkError {
pub kind: UpdateFrameworkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateFrameworkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateFrameworkErrorKind {
AlreadyExistsException(crate::error::AlreadyExistsException),
ConflictException(crate::error::ConflictException),
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 UpdateFrameworkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateFrameworkErrorKind::AlreadyExistsException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::ConflictException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UpdateFrameworkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateFrameworkError {
fn code(&self) -> Option<&str> {
UpdateFrameworkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateFrameworkError {
pub fn new(kind: UpdateFrameworkErrorKind, 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: UpdateFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateFrameworkErrorKind::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_already_exists_exception(&self) -> bool {
matches!(
&self.kind,
UpdateFrameworkErrorKind::AlreadyExistsException(_)
)
}
pub fn is_conflict_exception(&self) -> bool {
matches!(&self.kind, UpdateFrameworkErrorKind::ConflictException(_))
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateFrameworkErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
UpdateFrameworkErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateFrameworkErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UpdateFrameworkErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UpdateFrameworkErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UpdateFrameworkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateFrameworkErrorKind::AlreadyExistsException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::ConflictException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::LimitExceededException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UpdateFrameworkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct LimitExceededException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl LimitExceededException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.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_7) = &self.message {
{
write!(f, ": {}", inner_7)?;
}
}
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) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::LimitExceededException {
crate::error::LimitExceededException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl LimitExceededException {
pub fn builder() -> crate::error::limit_exceeded_exception::Builder {
crate::error::limit_exceeded_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct AlreadyExistsException {
#[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>,
#[doc(hidden)]
pub creator_request_id: std::option::Option<std::string::String>,
#[doc(hidden)]
pub arn: std::option::Option<std::string::String>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl AlreadyExistsException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn creator_request_id(&self) -> std::option::Option<&str> {
self.creator_request_id.as_deref()
}
pub fn arn(&self) -> std::option::Option<&str> {
self.arn.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.as_deref()
}
}
impl AlreadyExistsException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for AlreadyExistsException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "AlreadyExistsException")?;
if let Some(inner_8) = &self.message {
{
write!(f, ": {}", inner_8)?;
}
}
Ok(())
}
}
impl std::error::Error for AlreadyExistsException {}
pub mod already_exists_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) creator_request_id: std::option::Option<std::string::String>,
pub(crate) arn: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 creator_request_id(mut self, input: impl Into<std::string::String>) -> Self {
self.creator_request_id = Some(input.into());
self
}
pub fn set_creator_request_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.creator_request_id = input;
self
}
pub fn arn(mut self, input: impl Into<std::string::String>) -> Self {
self.arn = Some(input.into());
self
}
pub fn set_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.arn = input;
self
}
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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::AlreadyExistsException {
crate::error::AlreadyExistsException {
code: self.code,
message: self.message,
creator_request_id: self.creator_request_id,
arn: self.arn,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl AlreadyExistsException {
pub fn builder() -> crate::error::already_exists_exception::Builder {
crate::error::already_exists_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateBackupPlanError {
pub kind: UpdateBackupPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateBackupPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateBackupPlanErrorKind {
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 UpdateBackupPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateBackupPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UpdateBackupPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UpdateBackupPlanErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UpdateBackupPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UpdateBackupPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateBackupPlanError {
fn code(&self) -> Option<&str> {
UpdateBackupPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateBackupPlanError {
pub fn new(kind: UpdateBackupPlanErrorKind, 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: UpdateBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateBackupPlanErrorKind::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,
UpdateBackupPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UpdateBackupPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UpdateBackupPlanErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UpdateBackupPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UpdateBackupPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateBackupPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UpdateBackupPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UpdateBackupPlanErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UpdateBackupPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UpdateBackupPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UntagResourceError {
pub kind: UntagResourceErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UntagResourceError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UntagResourceErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UntagResourceErrorKind {
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 UntagResourceError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UntagResourceErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
UntagResourceErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
UntagResourceErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UntagResourceErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
UntagResourceErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UntagResourceError {
fn code(&self) -> Option<&str> {
UntagResourceError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UntagResourceError {
pub fn new(kind: UntagResourceErrorKind, 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: UntagResourceErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UntagResourceErrorKind::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,
UntagResourceErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
UntagResourceErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UntagResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
UntagResourceErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for UntagResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UntagResourceErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
UntagResourceErrorKind::MissingParameterValueException(_inner) => Some(_inner),
UntagResourceErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UntagResourceErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
UntagResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct TagResourceError {
pub kind: TagResourceErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for TagResourceError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: TagResourceErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum TagResourceErrorKind {
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 TagResourceError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
TagResourceErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
TagResourceErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
TagResourceErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
TagResourceErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
TagResourceErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
TagResourceErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for TagResourceError {
fn code(&self) -> Option<&str> {
TagResourceError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl TagResourceError {
pub fn new(kind: TagResourceErrorKind, 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: TagResourceErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: TagResourceErrorKind::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,
TagResourceErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(&self.kind, TagResourceErrorKind::LimitExceededException(_))
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
TagResourceErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
TagResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
TagResourceErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for TagResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
TagResourceErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
TagResourceErrorKind::LimitExceededException(_inner) => Some(_inner),
TagResourceErrorKind::MissingParameterValueException(_inner) => Some(_inner),
TagResourceErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
TagResourceErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
TagResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct StopBackupJobError {
pub kind: StopBackupJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for StopBackupJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: StopBackupJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum StopBackupJobErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for StopBackupJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
StopBackupJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
StopBackupJobErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
StopBackupJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
StopBackupJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
StopBackupJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
StopBackupJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for StopBackupJobError {
fn code(&self) -> Option<&str> {
StopBackupJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl StopBackupJobError {
pub fn new(kind: StopBackupJobErrorKind, 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: StopBackupJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: StopBackupJobErrorKind::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,
StopBackupJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
StopBackupJobErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
StopBackupJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
StopBackupJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
StopBackupJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for StopBackupJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
StopBackupJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
StopBackupJobErrorKind::InvalidRequestException(_inner) => Some(_inner),
StopBackupJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
StopBackupJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
StopBackupJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
StopBackupJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct StartRestoreJobError {
pub kind: StartRestoreJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for StartRestoreJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: StartRestoreJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum StartRestoreJobErrorKind {
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 StartRestoreJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
StartRestoreJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
StartRestoreJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
StartRestoreJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
StartRestoreJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
StartRestoreJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for StartRestoreJobError {
fn code(&self) -> Option<&str> {
StartRestoreJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl StartRestoreJobError {
pub fn new(kind: StartRestoreJobErrorKind, 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: StartRestoreJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: StartRestoreJobErrorKind::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,
StartRestoreJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
StartRestoreJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
StartRestoreJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
StartRestoreJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for StartRestoreJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
StartRestoreJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
StartRestoreJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
StartRestoreJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
StartRestoreJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
StartRestoreJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct StartReportJobError {
pub kind: StartReportJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for StartReportJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: StartReportJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum StartReportJobErrorKind {
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 StartReportJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
StartReportJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
StartReportJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
StartReportJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
StartReportJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
StartReportJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for StartReportJobError {
fn code(&self) -> Option<&str> {
StartReportJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl StartReportJobError {
pub fn new(kind: StartReportJobErrorKind, 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: StartReportJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: StartReportJobErrorKind::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,
StartReportJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
StartReportJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
StartReportJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
StartReportJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for StartReportJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
StartReportJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
StartReportJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
StartReportJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
StartReportJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
StartReportJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct StartCopyJobError {
pub kind: StartCopyJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for StartCopyJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: StartCopyJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum StartCopyJobErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
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 StartCopyJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
StartCopyJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
StartCopyJobErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
StartCopyJobErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
StartCopyJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
StartCopyJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
StartCopyJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
StartCopyJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for StartCopyJobError {
fn code(&self) -> Option<&str> {
StartCopyJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl StartCopyJobError {
pub fn new(kind: StartCopyJobErrorKind, 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: StartCopyJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: StartCopyJobErrorKind::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,
StartCopyJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
StartCopyJobErrorKind::InvalidRequestException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(&self.kind, StartCopyJobErrorKind::LimitExceededException(_))
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
StartCopyJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
StartCopyJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
StartCopyJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for StartCopyJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
StartCopyJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
StartCopyJobErrorKind::InvalidRequestException(_inner) => Some(_inner),
StartCopyJobErrorKind::LimitExceededException(_inner) => Some(_inner),
StartCopyJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
StartCopyJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
StartCopyJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
StartCopyJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct StartBackupJobError {
pub kind: StartBackupJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for StartBackupJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: StartBackupJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum StartBackupJobErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
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 StartBackupJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
StartBackupJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
StartBackupJobErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
StartBackupJobErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
StartBackupJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
StartBackupJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
StartBackupJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
StartBackupJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for StartBackupJobError {
fn code(&self) -> Option<&str> {
StartBackupJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl StartBackupJobError {
pub fn new(kind: StartBackupJobErrorKind, 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: StartBackupJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: StartBackupJobErrorKind::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,
StartBackupJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
StartBackupJobErrorKind::InvalidRequestException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
StartBackupJobErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
StartBackupJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
StartBackupJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
StartBackupJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for StartBackupJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
StartBackupJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
StartBackupJobErrorKind::InvalidRequestException(_inner) => Some(_inner),
StartBackupJobErrorKind::LimitExceededException(_inner) => Some(_inner),
StartBackupJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
StartBackupJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
StartBackupJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
StartBackupJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PutBackupVaultNotificationsError {
pub kind: PutBackupVaultNotificationsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for PutBackupVaultNotificationsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: PutBackupVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PutBackupVaultNotificationsErrorKind {
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 PutBackupVaultNotificationsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PutBackupVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultNotificationsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PutBackupVaultNotificationsError {
fn code(&self) -> Option<&str> {
PutBackupVaultNotificationsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl PutBackupVaultNotificationsError {
pub fn new(kind: PutBackupVaultNotificationsErrorKind, 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: PutBackupVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PutBackupVaultNotificationsErrorKind::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,
PutBackupVaultNotificationsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultNotificationsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultNotificationsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultNotificationsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for PutBackupVaultNotificationsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PutBackupVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
PutBackupVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
PutBackupVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
PutBackupVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
PutBackupVaultNotificationsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PutBackupVaultLockConfigurationError {
pub kind: PutBackupVaultLockConfigurationErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for PutBackupVaultLockConfigurationError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: PutBackupVaultLockConfigurationErrorKind::Unhandled(
crate::error::Unhandled::new(source),
),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PutBackupVaultLockConfigurationErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for PutBackupVaultLockConfigurationError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PutBackupVaultLockConfigurationErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultLockConfigurationErrorKind::InvalidRequestException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultLockConfigurationErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultLockConfigurationErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultLockConfigurationErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultLockConfigurationErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PutBackupVaultLockConfigurationError {
fn code(&self) -> Option<&str> {
PutBackupVaultLockConfigurationError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl PutBackupVaultLockConfigurationError {
pub fn new(
kind: PutBackupVaultLockConfigurationErrorKind,
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: PutBackupVaultLockConfigurationErrorKind::Unhandled(
crate::error::Unhandled::new(err.into()),
),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PutBackupVaultLockConfigurationErrorKind::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,
PutBackupVaultLockConfigurationErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultLockConfigurationErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultLockConfigurationErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultLockConfigurationErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultLockConfigurationErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for PutBackupVaultLockConfigurationError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PutBackupVaultLockConfigurationErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
PutBackupVaultLockConfigurationErrorKind::InvalidRequestException(_inner) => {
Some(_inner)
}
PutBackupVaultLockConfigurationErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
PutBackupVaultLockConfigurationErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
PutBackupVaultLockConfigurationErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
PutBackupVaultLockConfigurationErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PutBackupVaultAccessPolicyError {
pub kind: PutBackupVaultAccessPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for PutBackupVaultAccessPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: PutBackupVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PutBackupVaultAccessPolicyErrorKind {
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 PutBackupVaultAccessPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PutBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
PutBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
PutBackupVaultAccessPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PutBackupVaultAccessPolicyError {
fn code(&self) -> Option<&str> {
PutBackupVaultAccessPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl PutBackupVaultAccessPolicyError {
pub fn new(kind: PutBackupVaultAccessPolicyErrorKind, 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: PutBackupVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PutBackupVaultAccessPolicyErrorKind::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,
PutBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
PutBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for PutBackupVaultAccessPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PutBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
PutBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
PutBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
PutBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
PutBackupVaultAccessPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListTagsError {
pub kind: ListTagsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListTagsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListTagsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListTagsErrorKind {
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 ListTagsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListTagsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListTagsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListTagsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListTagsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListTagsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListTagsError {
fn code(&self) -> Option<&str> {
ListTagsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListTagsError {
pub fn new(kind: ListTagsErrorKind, 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: ListTagsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListTagsErrorKind::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,
ListTagsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, ListTagsErrorKind::ResourceNotFoundException(_))
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListTagsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListTagsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListTagsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListTagsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListTagsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListTagsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListRestoreJobsError {
pub kind: ListRestoreJobsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListRestoreJobsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListRestoreJobsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListRestoreJobsErrorKind {
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 ListRestoreJobsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListRestoreJobsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListRestoreJobsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListRestoreJobsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListRestoreJobsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListRestoreJobsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListRestoreJobsError {
fn code(&self) -> Option<&str> {
ListRestoreJobsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListRestoreJobsError {
pub fn new(kind: ListRestoreJobsErrorKind, 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: ListRestoreJobsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListRestoreJobsErrorKind::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,
ListRestoreJobsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListRestoreJobsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListRestoreJobsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListRestoreJobsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListRestoreJobsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListRestoreJobsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListRestoreJobsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListRestoreJobsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListRestoreJobsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListRestoreJobsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListReportPlansError {
pub kind: ListReportPlansErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListReportPlansError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListReportPlansErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListReportPlansErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListReportPlansError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListReportPlansErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListReportPlansErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListReportPlansErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListReportPlansError {
fn code(&self) -> Option<&str> {
ListReportPlansError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListReportPlansError {
pub fn new(kind: ListReportPlansErrorKind, 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: ListReportPlansErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListReportPlansErrorKind::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,
ListReportPlansErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListReportPlansErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListReportPlansError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListReportPlansErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListReportPlansErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListReportPlansErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListReportJobsError {
pub kind: ListReportJobsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListReportJobsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListReportJobsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListReportJobsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListReportJobsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListReportJobsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListReportJobsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListReportJobsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListReportJobsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListReportJobsError {
fn code(&self) -> Option<&str> {
ListReportJobsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListReportJobsError {
pub fn new(kind: ListReportJobsErrorKind, 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: ListReportJobsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListReportJobsErrorKind::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,
ListReportJobsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListReportJobsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListReportJobsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListReportJobsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListReportJobsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListReportJobsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListReportJobsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListReportJobsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListRecoveryPointsByResourceError {
pub kind: ListRecoveryPointsByResourceErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListRecoveryPointsByResourceError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListRecoveryPointsByResourceErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListRecoveryPointsByResourceErrorKind {
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 ListRecoveryPointsByResourceError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListRecoveryPointsByResourceErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByResourceErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByResourceErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByResourceErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByResourceErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListRecoveryPointsByResourceError {
fn code(&self) -> Option<&str> {
ListRecoveryPointsByResourceError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListRecoveryPointsByResourceError {
pub fn new(kind: ListRecoveryPointsByResourceErrorKind, 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: ListRecoveryPointsByResourceErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListRecoveryPointsByResourceErrorKind::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,
ListRecoveryPointsByResourceErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByResourceErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByResourceErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListRecoveryPointsByResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListRecoveryPointsByResourceErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByResourceErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByResourceErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByResourceErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListRecoveryPointsByLegalHoldError {
pub kind: ListRecoveryPointsByLegalHoldErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListRecoveryPointsByLegalHoldError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListRecoveryPointsByLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListRecoveryPointsByLegalHoldErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListRecoveryPointsByLegalHoldError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListRecoveryPointsByLegalHoldErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByLegalHoldErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByLegalHoldErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByLegalHoldErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListRecoveryPointsByLegalHoldError {
fn code(&self) -> Option<&str> {
ListRecoveryPointsByLegalHoldError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListRecoveryPointsByLegalHoldError {
pub fn new(
kind: ListRecoveryPointsByLegalHoldErrorKind,
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: ListRecoveryPointsByLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListRecoveryPointsByLegalHoldErrorKind::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,
ListRecoveryPointsByLegalHoldErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByLegalHoldErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByLegalHoldErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListRecoveryPointsByLegalHoldError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListRecoveryPointsByLegalHoldErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByLegalHoldErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByLegalHoldErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByLegalHoldErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListRecoveryPointsByBackupVaultError {
pub kind: ListRecoveryPointsByBackupVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListRecoveryPointsByBackupVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListRecoveryPointsByBackupVaultErrorKind::Unhandled(
crate::error::Unhandled::new(source),
),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListRecoveryPointsByBackupVaultErrorKind {
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 ListRecoveryPointsByBackupVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListRecoveryPointsByBackupVaultErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByBackupVaultErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByBackupVaultErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByBackupVaultErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
ListRecoveryPointsByBackupVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListRecoveryPointsByBackupVaultError {
fn code(&self) -> Option<&str> {
ListRecoveryPointsByBackupVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListRecoveryPointsByBackupVaultError {
pub fn new(
kind: ListRecoveryPointsByBackupVaultErrorKind,
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: ListRecoveryPointsByBackupVaultErrorKind::Unhandled(
crate::error::Unhandled::new(err.into()),
),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListRecoveryPointsByBackupVaultErrorKind::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,
ListRecoveryPointsByBackupVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByBackupVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByBackupVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListRecoveryPointsByBackupVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListRecoveryPointsByBackupVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListRecoveryPointsByBackupVaultErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByBackupVaultErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByBackupVaultErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByBackupVaultErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
ListRecoveryPointsByBackupVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListProtectedResourcesError {
pub kind: ListProtectedResourcesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListProtectedResourcesError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListProtectedResourcesErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListProtectedResourcesErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListProtectedResourcesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListProtectedResourcesErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListProtectedResourcesErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListProtectedResourcesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListProtectedResourcesError {
fn code(&self) -> Option<&str> {
ListProtectedResourcesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListProtectedResourcesError {
pub fn new(kind: ListProtectedResourcesErrorKind, 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: ListProtectedResourcesErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListProtectedResourcesErrorKind::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,
ListProtectedResourcesErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListProtectedResourcesErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListProtectedResourcesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListProtectedResourcesErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListProtectedResourcesErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListProtectedResourcesErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListLegalHoldsError {
pub kind: ListLegalHoldsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListLegalHoldsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListLegalHoldsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListLegalHoldsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListLegalHoldsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListLegalHoldsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListLegalHoldsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListLegalHoldsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListLegalHoldsError {
fn code(&self) -> Option<&str> {
ListLegalHoldsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListLegalHoldsError {
pub fn new(kind: ListLegalHoldsErrorKind, 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: ListLegalHoldsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListLegalHoldsErrorKind::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,
ListLegalHoldsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListLegalHoldsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListLegalHoldsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListLegalHoldsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListLegalHoldsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListLegalHoldsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListFrameworksError {
pub kind: ListFrameworksErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListFrameworksError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListFrameworksErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListFrameworksErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListFrameworksError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListFrameworksErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListFrameworksErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListFrameworksErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListFrameworksError {
fn code(&self) -> Option<&str> {
ListFrameworksError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListFrameworksError {
pub fn new(kind: ListFrameworksErrorKind, 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: ListFrameworksErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListFrameworksErrorKind::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,
ListFrameworksErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListFrameworksErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListFrameworksError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListFrameworksErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListFrameworksErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListFrameworksErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListCopyJobsError {
pub kind: ListCopyJobsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListCopyJobsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListCopyJobsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListCopyJobsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListCopyJobsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListCopyJobsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListCopyJobsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListCopyJobsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListCopyJobsError {
fn code(&self) -> Option<&str> {
ListCopyJobsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListCopyJobsError {
pub fn new(kind: ListCopyJobsErrorKind, 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: ListCopyJobsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListCopyJobsErrorKind::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,
ListCopyJobsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListCopyJobsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListCopyJobsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListCopyJobsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListCopyJobsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListCopyJobsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListBackupVaultsError {
pub kind: ListBackupVaultsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListBackupVaultsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListBackupVaultsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListBackupVaultsErrorKind {
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 ListBackupVaultsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListBackupVaultsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListBackupVaultsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListBackupVaultsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListBackupVaultsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListBackupVaultsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListBackupVaultsError {
fn code(&self) -> Option<&str> {
ListBackupVaultsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListBackupVaultsError {
pub fn new(kind: ListBackupVaultsErrorKind, 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: ListBackupVaultsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListBackupVaultsErrorKind::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,
ListBackupVaultsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupVaultsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupVaultsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupVaultsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListBackupVaultsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListBackupVaultsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListBackupVaultsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListBackupVaultsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListBackupVaultsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListBackupVaultsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListBackupSelectionsError {
pub kind: ListBackupSelectionsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListBackupSelectionsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListBackupSelectionsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListBackupSelectionsErrorKind {
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 ListBackupSelectionsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListBackupSelectionsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListBackupSelectionsErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListBackupSelectionsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListBackupSelectionsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListBackupSelectionsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListBackupSelectionsError {
fn code(&self) -> Option<&str> {
ListBackupSelectionsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListBackupSelectionsError {
pub fn new(kind: ListBackupSelectionsErrorKind, 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: ListBackupSelectionsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListBackupSelectionsErrorKind::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,
ListBackupSelectionsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupSelectionsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupSelectionsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupSelectionsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListBackupSelectionsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListBackupSelectionsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListBackupSelectionsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListBackupSelectionsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListBackupSelectionsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListBackupSelectionsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListBackupPlanVersionsError {
pub kind: ListBackupPlanVersionsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListBackupPlanVersionsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListBackupPlanVersionsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListBackupPlanVersionsErrorKind {
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 ListBackupPlanVersionsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListBackupPlanVersionsErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListBackupPlanVersionsErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ListBackupPlanVersionsErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListBackupPlanVersionsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListBackupPlanVersionsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListBackupPlanVersionsError {
fn code(&self) -> Option<&str> {
ListBackupPlanVersionsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListBackupPlanVersionsError {
pub fn new(kind: ListBackupPlanVersionsErrorKind, 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: ListBackupPlanVersionsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListBackupPlanVersionsErrorKind::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,
ListBackupPlanVersionsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlanVersionsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlanVersionsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlanVersionsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListBackupPlanVersionsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListBackupPlanVersionsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListBackupPlanVersionsErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListBackupPlanVersionsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListBackupPlanVersionsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListBackupPlanVersionsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListBackupPlanTemplatesError {
pub kind: ListBackupPlanTemplatesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListBackupPlanTemplatesError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListBackupPlanTemplatesErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListBackupPlanTemplatesErrorKind {
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 ListBackupPlanTemplatesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListBackupPlanTemplatesErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ListBackupPlanTemplatesErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ListBackupPlanTemplatesErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListBackupPlanTemplatesErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListBackupPlanTemplatesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListBackupPlanTemplatesError {
fn code(&self) -> Option<&str> {
ListBackupPlanTemplatesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListBackupPlanTemplatesError {
pub fn new(kind: ListBackupPlanTemplatesErrorKind, 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: ListBackupPlanTemplatesErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListBackupPlanTemplatesErrorKind::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,
ListBackupPlanTemplatesErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlanTemplatesErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlanTemplatesErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlanTemplatesErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListBackupPlanTemplatesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListBackupPlanTemplatesErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
ListBackupPlanTemplatesErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
ListBackupPlanTemplatesErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListBackupPlanTemplatesErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListBackupPlanTemplatesErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListBackupPlansError {
pub kind: ListBackupPlansErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListBackupPlansError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListBackupPlansErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListBackupPlansErrorKind {
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 ListBackupPlansError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListBackupPlansErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListBackupPlansErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
ListBackupPlansErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListBackupPlansErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListBackupPlansErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListBackupPlansError {
fn code(&self) -> Option<&str> {
ListBackupPlansError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListBackupPlansError {
pub fn new(kind: ListBackupPlansErrorKind, 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: ListBackupPlansErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListBackupPlansErrorKind::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,
ListBackupPlansErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlansErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlansErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupPlansErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListBackupPlansError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListBackupPlansErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListBackupPlansErrorKind::MissingParameterValueException(_inner) => Some(_inner),
ListBackupPlansErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListBackupPlansErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListBackupPlansErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListBackupJobsError {
pub kind: ListBackupJobsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListBackupJobsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListBackupJobsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListBackupJobsErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListBackupJobsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListBackupJobsErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
ListBackupJobsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ListBackupJobsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListBackupJobsError {
fn code(&self) -> Option<&str> {
ListBackupJobsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListBackupJobsError {
pub fn new(kind: ListBackupJobsErrorKind, 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: ListBackupJobsErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListBackupJobsErrorKind::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,
ListBackupJobsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ListBackupJobsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ListBackupJobsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListBackupJobsErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
ListBackupJobsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ListBackupJobsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetSupportedResourceTypesError {
pub kind: GetSupportedResourceTypesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetSupportedResourceTypesError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetSupportedResourceTypesErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetSupportedResourceTypesErrorKind {
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetSupportedResourceTypesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetSupportedResourceTypesErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
GetSupportedResourceTypesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetSupportedResourceTypesError {
fn code(&self) -> Option<&str> {
GetSupportedResourceTypesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetSupportedResourceTypesError {
pub fn new(kind: GetSupportedResourceTypesErrorKind, 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: GetSupportedResourceTypesErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetSupportedResourceTypesErrorKind::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_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetSupportedResourceTypesErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetSupportedResourceTypesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetSupportedResourceTypesErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetSupportedResourceTypesErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetRecoveryPointRestoreMetadataError {
pub kind: GetRecoveryPointRestoreMetadataErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetRecoveryPointRestoreMetadataError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetRecoveryPointRestoreMetadataErrorKind::Unhandled(
crate::error::Unhandled::new(source),
),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetRecoveryPointRestoreMetadataErrorKind {
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 GetRecoveryPointRestoreMetadataError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetRecoveryPointRestoreMetadataErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
GetRecoveryPointRestoreMetadataErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
GetRecoveryPointRestoreMetadataErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
GetRecoveryPointRestoreMetadataErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
GetRecoveryPointRestoreMetadataErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetRecoveryPointRestoreMetadataError {
fn code(&self) -> Option<&str> {
GetRecoveryPointRestoreMetadataError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetRecoveryPointRestoreMetadataError {
pub fn new(
kind: GetRecoveryPointRestoreMetadataErrorKind,
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: GetRecoveryPointRestoreMetadataErrorKind::Unhandled(
crate::error::Unhandled::new(err.into()),
),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetRecoveryPointRestoreMetadataErrorKind::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,
GetRecoveryPointRestoreMetadataErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetRecoveryPointRestoreMetadataErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetRecoveryPointRestoreMetadataErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetRecoveryPointRestoreMetadataErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetRecoveryPointRestoreMetadataError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetRecoveryPointRestoreMetadataErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
GetRecoveryPointRestoreMetadataErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
GetRecoveryPointRestoreMetadataErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
GetRecoveryPointRestoreMetadataErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
GetRecoveryPointRestoreMetadataErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetLegalHoldError {
pub kind: GetLegalHoldErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetLegalHoldError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetLegalHoldErrorKind {
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 GetLegalHoldError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetLegalHoldErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetLegalHoldErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetLegalHoldErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetLegalHoldErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetLegalHoldErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetLegalHoldError {
fn code(&self) -> Option<&str> {
GetLegalHoldError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetLegalHoldError {
pub fn new(kind: GetLegalHoldErrorKind, 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: GetLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetLegalHoldErrorKind::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,
GetLegalHoldErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetLegalHoldErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetLegalHoldErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetLegalHoldErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetLegalHoldError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetLegalHoldErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetLegalHoldErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetLegalHoldErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetLegalHoldErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetLegalHoldErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetBackupVaultNotificationsError {
pub kind: GetBackupVaultNotificationsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetBackupVaultNotificationsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetBackupVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetBackupVaultNotificationsErrorKind {
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 GetBackupVaultNotificationsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetBackupVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultNotificationsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetBackupVaultNotificationsError {
fn code(&self) -> Option<&str> {
GetBackupVaultNotificationsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetBackupVaultNotificationsError {
pub fn new(kind: GetBackupVaultNotificationsErrorKind, 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: GetBackupVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetBackupVaultNotificationsErrorKind::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,
GetBackupVaultNotificationsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupVaultNotificationsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupVaultNotificationsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupVaultNotificationsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetBackupVaultNotificationsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetBackupVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
GetBackupVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
GetBackupVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetBackupVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
GetBackupVaultNotificationsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetBackupVaultAccessPolicyError {
pub kind: GetBackupVaultAccessPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetBackupVaultAccessPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetBackupVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetBackupVaultAccessPolicyErrorKind {
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 GetBackupVaultAccessPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
GetBackupVaultAccessPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetBackupVaultAccessPolicyError {
fn code(&self) -> Option<&str> {
GetBackupVaultAccessPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetBackupVaultAccessPolicyError {
pub fn new(kind: GetBackupVaultAccessPolicyErrorKind, 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: GetBackupVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetBackupVaultAccessPolicyErrorKind::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,
GetBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetBackupVaultAccessPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
GetBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
GetBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
GetBackupVaultAccessPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetBackupSelectionError {
pub kind: GetBackupSelectionErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetBackupSelectionError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetBackupSelectionErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetBackupSelectionErrorKind {
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 GetBackupSelectionError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetBackupSelectionErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetBackupSelectionErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetBackupSelectionErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetBackupSelectionErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetBackupSelectionErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetBackupSelectionError {
fn code(&self) -> Option<&str> {
GetBackupSelectionError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetBackupSelectionError {
pub fn new(kind: GetBackupSelectionErrorKind, 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: GetBackupSelectionErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetBackupSelectionErrorKind::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,
GetBackupSelectionErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupSelectionErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupSelectionErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupSelectionErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetBackupSelectionError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetBackupSelectionErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetBackupSelectionErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetBackupSelectionErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetBackupSelectionErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetBackupSelectionErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetBackupPlanFromTemplateError {
pub kind: GetBackupPlanFromTemplateErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetBackupPlanFromTemplateError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetBackupPlanFromTemplateErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetBackupPlanFromTemplateErrorKind {
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 GetBackupPlanFromTemplateError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetBackupPlanFromTemplateErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
GetBackupPlanFromTemplateErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
GetBackupPlanFromTemplateErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetBackupPlanFromTemplateErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
GetBackupPlanFromTemplateErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetBackupPlanFromTemplateError {
fn code(&self) -> Option<&str> {
GetBackupPlanFromTemplateError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetBackupPlanFromTemplateError {
pub fn new(kind: GetBackupPlanFromTemplateErrorKind, 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: GetBackupPlanFromTemplateErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetBackupPlanFromTemplateErrorKind::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,
GetBackupPlanFromTemplateErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromTemplateErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromTemplateErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromTemplateErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetBackupPlanFromTemplateError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetBackupPlanFromTemplateErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
GetBackupPlanFromTemplateErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
GetBackupPlanFromTemplateErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetBackupPlanFromTemplateErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetBackupPlanFromTemplateErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetBackupPlanFromJSONError {
pub kind: GetBackupPlanFromJSONErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetBackupPlanFromJSONError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetBackupPlanFromJSONErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetBackupPlanFromJSONErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
LimitExceededException(crate::error::LimitExceededException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetBackupPlanFromJSONError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetBackupPlanFromJSONErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetBackupPlanFromJSONErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
GetBackupPlanFromJSONErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
GetBackupPlanFromJSONErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetBackupPlanFromJSONErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetBackupPlanFromJSONErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetBackupPlanFromJSONError {
fn code(&self) -> Option<&str> {
GetBackupPlanFromJSONError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetBackupPlanFromJSONError {
pub fn new(kind: GetBackupPlanFromJSONErrorKind, 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: GetBackupPlanFromJSONErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetBackupPlanFromJSONErrorKind::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,
GetBackupPlanFromJSONErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromJSONErrorKind::InvalidRequestException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromJSONErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromJSONErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanFromJSONErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetBackupPlanFromJSONError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetBackupPlanFromJSONErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetBackupPlanFromJSONErrorKind::InvalidRequestException(_inner) => Some(_inner),
GetBackupPlanFromJSONErrorKind::LimitExceededException(_inner) => Some(_inner),
GetBackupPlanFromJSONErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetBackupPlanFromJSONErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetBackupPlanFromJSONErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetBackupPlanError {
pub kind: GetBackupPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetBackupPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetBackupPlanErrorKind {
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 GetBackupPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetBackupPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
GetBackupPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
GetBackupPlanErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetBackupPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
GetBackupPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetBackupPlanError {
fn code(&self) -> Option<&str> {
GetBackupPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetBackupPlanError {
pub fn new(kind: GetBackupPlanErrorKind, 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: GetBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetBackupPlanErrorKind::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,
GetBackupPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
GetBackupPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for GetBackupPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetBackupPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
GetBackupPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
GetBackupPlanErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetBackupPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
GetBackupPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ExportBackupPlanTemplateError {
pub kind: ExportBackupPlanTemplateErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ExportBackupPlanTemplateError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ExportBackupPlanTemplateErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ExportBackupPlanTemplateErrorKind {
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 ExportBackupPlanTemplateError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ExportBackupPlanTemplateErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
ExportBackupPlanTemplateErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
ExportBackupPlanTemplateErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ExportBackupPlanTemplateErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
ExportBackupPlanTemplateErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ExportBackupPlanTemplateError {
fn code(&self) -> Option<&str> {
ExportBackupPlanTemplateError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ExportBackupPlanTemplateError {
pub fn new(kind: ExportBackupPlanTemplateErrorKind, 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: ExportBackupPlanTemplateErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ExportBackupPlanTemplateErrorKind::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,
ExportBackupPlanTemplateErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
ExportBackupPlanTemplateErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ExportBackupPlanTemplateErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
ExportBackupPlanTemplateErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for ExportBackupPlanTemplateError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ExportBackupPlanTemplateErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
ExportBackupPlanTemplateErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
ExportBackupPlanTemplateErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ExportBackupPlanTemplateErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
ExportBackupPlanTemplateErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DisassociateRecoveryPointFromParentError {
pub kind: DisassociateRecoveryPointFromParentErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DisassociateRecoveryPointFromParentError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DisassociateRecoveryPointFromParentErrorKind::Unhandled(
crate::error::Unhandled::new(source),
),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DisassociateRecoveryPointFromParentErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DisassociateRecoveryPointFromParentError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DisassociateRecoveryPointFromParentErrorKind::InvalidParameterValueException(
_inner,
) => _inner.fmt(f),
DisassociateRecoveryPointFromParentErrorKind::InvalidRequestException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointFromParentErrorKind::MissingParameterValueException(
_inner,
) => _inner.fmt(f),
DisassociateRecoveryPointFromParentErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointFromParentErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointFromParentErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DisassociateRecoveryPointFromParentError {
fn code(&self) -> Option<&str> {
DisassociateRecoveryPointFromParentError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DisassociateRecoveryPointFromParentError {
pub fn new(
kind: DisassociateRecoveryPointFromParentErrorKind,
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: DisassociateRecoveryPointFromParentErrorKind::Unhandled(
crate::error::Unhandled::new(err.into()),
),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DisassociateRecoveryPointFromParentErrorKind::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,
DisassociateRecoveryPointFromParentErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointFromParentErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointFromParentErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointFromParentErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointFromParentErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DisassociateRecoveryPointFromParentError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DisassociateRecoveryPointFromParentErrorKind::InvalidParameterValueException(
_inner,
) => Some(_inner),
DisassociateRecoveryPointFromParentErrorKind::InvalidRequestException(_inner) => {
Some(_inner)
}
DisassociateRecoveryPointFromParentErrorKind::MissingParameterValueException(
_inner,
) => Some(_inner),
DisassociateRecoveryPointFromParentErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
DisassociateRecoveryPointFromParentErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
DisassociateRecoveryPointFromParentErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DisassociateRecoveryPointError {
pub kind: DisassociateRecoveryPointErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DisassociateRecoveryPointError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DisassociateRecoveryPointErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DisassociateRecoveryPointErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
InvalidResourceStateException(crate::error::InvalidResourceStateException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DisassociateRecoveryPointError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DisassociateRecoveryPointErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
DisassociateRecoveryPointErrorKind::InvalidResourceStateException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DisassociateRecoveryPointErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
DisassociateRecoveryPointErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DisassociateRecoveryPointError {
fn code(&self) -> Option<&str> {
DisassociateRecoveryPointError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DisassociateRecoveryPointError {
pub fn new(kind: DisassociateRecoveryPointErrorKind, 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: DisassociateRecoveryPointErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DisassociateRecoveryPointErrorKind::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,
DisassociateRecoveryPointErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointErrorKind::InvalidRequestException(_)
)
}
pub fn is_invalid_resource_state_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointErrorKind::InvalidResourceStateException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DisassociateRecoveryPointErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DisassociateRecoveryPointError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DisassociateRecoveryPointErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DisassociateRecoveryPointErrorKind::InvalidRequestException(_inner) => Some(_inner),
DisassociateRecoveryPointErrorKind::InvalidResourceStateException(_inner) => {
Some(_inner)
}
DisassociateRecoveryPointErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DisassociateRecoveryPointErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DisassociateRecoveryPointErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DisassociateRecoveryPointErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InvalidResourceStateException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl InvalidResourceStateException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.as_deref()
}
}
impl InvalidResourceStateException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InvalidResourceStateException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InvalidResourceStateException")?;
if let Some(inner_9) = &self.message {
{
write!(f, ": {}", inner_9)?;
}
}
Ok(())
}
}
impl std::error::Error for InvalidResourceStateException {}
pub mod invalid_resource_state_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::InvalidResourceStateException {
crate::error::InvalidResourceStateException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl InvalidResourceStateException {
pub fn builder() -> crate::error::invalid_resource_state_exception::Builder {
crate::error::invalid_resource_state_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeRestoreJobError {
pub kind: DescribeRestoreJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeRestoreJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeRestoreJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeRestoreJobErrorKind {
DependencyFailureException(crate::error::DependencyFailureException),
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 DescribeRestoreJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeRestoreJobErrorKind::DependencyFailureException(_inner) => _inner.fmt(f),
DescribeRestoreJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeRestoreJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeRestoreJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeRestoreJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeRestoreJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeRestoreJobError {
fn code(&self) -> Option<&str> {
DescribeRestoreJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeRestoreJobError {
pub fn new(kind: DescribeRestoreJobErrorKind, 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: DescribeRestoreJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeRestoreJobErrorKind::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_dependency_failure_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRestoreJobErrorKind::DependencyFailureException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRestoreJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRestoreJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRestoreJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRestoreJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeRestoreJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeRestoreJobErrorKind::DependencyFailureException(_inner) => Some(_inner),
DescribeRestoreJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeRestoreJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeRestoreJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeRestoreJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeRestoreJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct DependencyFailureException {
#[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>,
#[doc(hidden)]
pub r#type: std::option::Option<std::string::String>,
#[doc(hidden)]
pub context: std::option::Option<std::string::String>,
}
impl DependencyFailureException {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn r#type(&self) -> std::option::Option<&str> {
self.r#type.as_deref()
}
pub fn context(&self) -> std::option::Option<&str> {
self.context.as_deref()
}
}
impl DependencyFailureException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for DependencyFailureException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "DependencyFailureException")?;
if let Some(inner_10) = &self.message {
{
write!(f, ": {}", inner_10)?;
}
}
Ok(())
}
}
impl std::error::Error for DependencyFailureException {}
pub mod dependency_failure_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<std::string::String>,
pub(crate) context: std::option::Option<std::string::String>,
}
impl Builder {
#[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 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 context(mut self, input: impl Into<std::string::String>) -> Self {
self.context = Some(input.into());
self
}
pub fn set_context(mut self, input: std::option::Option<std::string::String>) -> Self {
self.context = input;
self
}
pub fn build(self) -> crate::error::DependencyFailureException {
crate::error::DependencyFailureException {
code: self.code,
message: self.message,
r#type: self.r#type,
context: self.context,
}
}
}
}
impl DependencyFailureException {
pub fn builder() -> crate::error::dependency_failure_exception::Builder {
crate::error::dependency_failure_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeReportPlanError {
pub kind: DescribeReportPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeReportPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeReportPlanErrorKind {
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 DescribeReportPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeReportPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeReportPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeReportPlanErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeReportPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeReportPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeReportPlanError {
fn code(&self) -> Option<&str> {
DescribeReportPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeReportPlanError {
pub fn new(kind: DescribeReportPlanErrorKind, 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: DescribeReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeReportPlanErrorKind::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,
DescribeReportPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeReportPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeReportPlanErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeReportPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeReportPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeReportPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeReportPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeReportPlanErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeReportPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeReportPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeReportJobError {
pub kind: DescribeReportJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeReportJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeReportJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeReportJobErrorKind {
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DescribeReportJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeReportJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeReportJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeReportJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeReportJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeReportJobError {
fn code(&self) -> Option<&str> {
DescribeReportJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeReportJobError {
pub fn new(kind: DescribeReportJobErrorKind, 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: DescribeReportJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeReportJobErrorKind::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_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeReportJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeReportJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeReportJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeReportJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeReportJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeReportJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeReportJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeReportJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeRegionSettingsError {
pub kind: DescribeRegionSettingsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeRegionSettingsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeRegionSettingsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeRegionSettingsErrorKind {
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DescribeRegionSettingsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeRegionSettingsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeRegionSettingsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeRegionSettingsError {
fn code(&self) -> Option<&str> {
DescribeRegionSettingsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeRegionSettingsError {
pub fn new(kind: DescribeRegionSettingsErrorKind, 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: DescribeRegionSettingsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeRegionSettingsErrorKind::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_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRegionSettingsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeRegionSettingsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeRegionSettingsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeRegionSettingsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeRecoveryPointError {
pub kind: DescribeRecoveryPointErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeRecoveryPointError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeRecoveryPointErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeRecoveryPointErrorKind {
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 DescribeRecoveryPointError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeRecoveryPointErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeRecoveryPointErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeRecoveryPointErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeRecoveryPointErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeRecoveryPointErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeRecoveryPointError {
fn code(&self) -> Option<&str> {
DescribeRecoveryPointError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeRecoveryPointError {
pub fn new(kind: DescribeRecoveryPointErrorKind, 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: DescribeRecoveryPointErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeRecoveryPointErrorKind::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,
DescribeRecoveryPointErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRecoveryPointErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRecoveryPointErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeRecoveryPointErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeRecoveryPointError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeRecoveryPointErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeRecoveryPointErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeRecoveryPointErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeRecoveryPointErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeRecoveryPointErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeProtectedResourceError {
pub kind: DescribeProtectedResourceErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeProtectedResourceError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeProtectedResourceErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeProtectedResourceErrorKind {
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 DescribeProtectedResourceError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeProtectedResourceErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DescribeProtectedResourceErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DescribeProtectedResourceErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeProtectedResourceErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
DescribeProtectedResourceErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeProtectedResourceError {
fn code(&self) -> Option<&str> {
DescribeProtectedResourceError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeProtectedResourceError {
pub fn new(kind: DescribeProtectedResourceErrorKind, 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: DescribeProtectedResourceErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeProtectedResourceErrorKind::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,
DescribeProtectedResourceErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeProtectedResourceErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeProtectedResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeProtectedResourceErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeProtectedResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeProtectedResourceErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DescribeProtectedResourceErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DescribeProtectedResourceErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeProtectedResourceErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeProtectedResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeGlobalSettingsError {
pub kind: DescribeGlobalSettingsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeGlobalSettingsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeGlobalSettingsErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeGlobalSettingsErrorKind {
InvalidRequestException(crate::error::InvalidRequestException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DescribeGlobalSettingsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeGlobalSettingsErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
DescribeGlobalSettingsErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeGlobalSettingsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeGlobalSettingsError {
fn code(&self) -> Option<&str> {
DescribeGlobalSettingsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeGlobalSettingsError {
pub fn new(kind: DescribeGlobalSettingsErrorKind, 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: DescribeGlobalSettingsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeGlobalSettingsErrorKind::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_request_exception(&self) -> bool {
matches!(
&self.kind,
DescribeGlobalSettingsErrorKind::InvalidRequestException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeGlobalSettingsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeGlobalSettingsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeGlobalSettingsErrorKind::InvalidRequestException(_inner) => Some(_inner),
DescribeGlobalSettingsErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeGlobalSettingsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeFrameworkError {
pub kind: DescribeFrameworkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeFrameworkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeFrameworkErrorKind {
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 DescribeFrameworkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeFrameworkErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeFrameworkErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeFrameworkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeFrameworkErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeFrameworkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeFrameworkError {
fn code(&self) -> Option<&str> {
DescribeFrameworkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeFrameworkError {
pub fn new(kind: DescribeFrameworkErrorKind, 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: DescribeFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeFrameworkErrorKind::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,
DescribeFrameworkErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeFrameworkErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeFrameworkErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeFrameworkErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeFrameworkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeFrameworkErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeFrameworkErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeFrameworkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeFrameworkErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeFrameworkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeCopyJobError {
pub kind: DescribeCopyJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeCopyJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeCopyJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeCopyJobErrorKind {
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 DescribeCopyJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeCopyJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeCopyJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeCopyJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeCopyJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeCopyJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeCopyJobError {
fn code(&self) -> Option<&str> {
DescribeCopyJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeCopyJobError {
pub fn new(kind: DescribeCopyJobErrorKind, 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: DescribeCopyJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeCopyJobErrorKind::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,
DescribeCopyJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeCopyJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeCopyJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeCopyJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeCopyJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeCopyJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeCopyJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeCopyJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeCopyJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeCopyJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeBackupVaultError {
pub kind: DescribeBackupVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeBackupVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeBackupVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeBackupVaultErrorKind {
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 DescribeBackupVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeBackupVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeBackupVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeBackupVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeBackupVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeBackupVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeBackupVaultError {
fn code(&self) -> Option<&str> {
DescribeBackupVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeBackupVaultError {
pub fn new(kind: DescribeBackupVaultErrorKind, 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: DescribeBackupVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeBackupVaultErrorKind::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,
DescribeBackupVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeBackupVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeBackupVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeBackupVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeBackupVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeBackupVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeBackupVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DescribeBackupJobError {
pub kind: DescribeBackupJobErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DescribeBackupJobError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DescribeBackupJobErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DescribeBackupJobErrorKind {
DependencyFailureException(crate::error::DependencyFailureException),
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 DescribeBackupJobError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DescribeBackupJobErrorKind::DependencyFailureException(_inner) => _inner.fmt(f),
DescribeBackupJobErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DescribeBackupJobErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DescribeBackupJobErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DescribeBackupJobErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DescribeBackupJobErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DescribeBackupJobError {
fn code(&self) -> Option<&str> {
DescribeBackupJobError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DescribeBackupJobError {
pub fn new(kind: DescribeBackupJobErrorKind, 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: DescribeBackupJobErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DescribeBackupJobErrorKind::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_dependency_failure_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupJobErrorKind::DependencyFailureException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupJobErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupJobErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupJobErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DescribeBackupJobErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DescribeBackupJobError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DescribeBackupJobErrorKind::DependencyFailureException(_inner) => Some(_inner),
DescribeBackupJobErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DescribeBackupJobErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DescribeBackupJobErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DescribeBackupJobErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DescribeBackupJobErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteReportPlanError {
pub kind: DeleteReportPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteReportPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteReportPlanErrorKind {
ConflictException(crate::error::ConflictException),
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 DeleteReportPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteReportPlanErrorKind::ConflictException(_inner) => _inner.fmt(f),
DeleteReportPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteReportPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteReportPlanErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteReportPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteReportPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteReportPlanError {
fn code(&self) -> Option<&str> {
DeleteReportPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteReportPlanError {
pub fn new(kind: DeleteReportPlanErrorKind, 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: DeleteReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteReportPlanErrorKind::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_conflict_exception(&self) -> bool {
matches!(&self.kind, DeleteReportPlanErrorKind::ConflictException(_))
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteReportPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteReportPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteReportPlanErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteReportPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteReportPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteReportPlanErrorKind::ConflictException(_inner) => Some(_inner),
DeleteReportPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteReportPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteReportPlanErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteReportPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteReportPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteRecoveryPointError {
pub kind: DeleteRecoveryPointErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteRecoveryPointError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteRecoveryPointErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteRecoveryPointErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
InvalidResourceStateException(crate::error::InvalidResourceStateException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteRecoveryPointError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteRecoveryPointErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteRecoveryPointErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
DeleteRecoveryPointErrorKind::InvalidResourceStateException(_inner) => _inner.fmt(f),
DeleteRecoveryPointErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteRecoveryPointErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteRecoveryPointErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteRecoveryPointErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteRecoveryPointError {
fn code(&self) -> Option<&str> {
DeleteRecoveryPointError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteRecoveryPointError {
pub fn new(kind: DeleteRecoveryPointErrorKind, 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: DeleteRecoveryPointErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteRecoveryPointErrorKind::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,
DeleteRecoveryPointErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
DeleteRecoveryPointErrorKind::InvalidRequestException(_)
)
}
pub fn is_invalid_resource_state_exception(&self) -> bool {
matches!(
&self.kind,
DeleteRecoveryPointErrorKind::InvalidResourceStateException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteRecoveryPointErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteRecoveryPointErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteRecoveryPointErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteRecoveryPointError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteRecoveryPointErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteRecoveryPointErrorKind::InvalidRequestException(_inner) => Some(_inner),
DeleteRecoveryPointErrorKind::InvalidResourceStateException(_inner) => Some(_inner),
DeleteRecoveryPointErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteRecoveryPointErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteRecoveryPointErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteRecoveryPointErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteFrameworkError {
pub kind: DeleteFrameworkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteFrameworkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteFrameworkErrorKind {
ConflictException(crate::error::ConflictException),
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 DeleteFrameworkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteFrameworkErrorKind::ConflictException(_inner) => _inner.fmt(f),
DeleteFrameworkErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteFrameworkErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteFrameworkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteFrameworkErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteFrameworkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteFrameworkError {
fn code(&self) -> Option<&str> {
DeleteFrameworkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteFrameworkError {
pub fn new(kind: DeleteFrameworkErrorKind, 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: DeleteFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteFrameworkErrorKind::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_conflict_exception(&self) -> bool {
matches!(&self.kind, DeleteFrameworkErrorKind::ConflictException(_))
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteFrameworkErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteFrameworkErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteFrameworkErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteFrameworkErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteFrameworkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteFrameworkErrorKind::ConflictException(_inner) => Some(_inner),
DeleteFrameworkErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteFrameworkErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteFrameworkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteFrameworkErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteFrameworkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteBackupVaultNotificationsError {
pub kind: DeleteBackupVaultNotificationsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteBackupVaultNotificationsError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteBackupVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteBackupVaultNotificationsErrorKind {
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 DeleteBackupVaultNotificationsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteBackupVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultNotificationsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteBackupVaultNotificationsError {
fn code(&self) -> Option<&str> {
DeleteBackupVaultNotificationsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteBackupVaultNotificationsError {
pub fn new(
kind: DeleteBackupVaultNotificationsErrorKind,
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: DeleteBackupVaultNotificationsErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteBackupVaultNotificationsErrorKind::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,
DeleteBackupVaultNotificationsErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultNotificationsErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultNotificationsErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultNotificationsErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteBackupVaultNotificationsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteBackupVaultNotificationsErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DeleteBackupVaultNotificationsErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DeleteBackupVaultNotificationsErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
DeleteBackupVaultNotificationsErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
DeleteBackupVaultNotificationsErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteBackupVaultLockConfigurationError {
pub kind: DeleteBackupVaultLockConfigurationErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteBackupVaultLockConfigurationError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteBackupVaultLockConfigurationErrorKind::Unhandled(
crate::error::Unhandled::new(source),
),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteBackupVaultLockConfigurationErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteBackupVaultLockConfigurationError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteBackupVaultLockConfigurationErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultLockConfigurationErrorKind::InvalidRequestException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultLockConfigurationErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultLockConfigurationErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultLockConfigurationErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultLockConfigurationErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteBackupVaultLockConfigurationError {
fn code(&self) -> Option<&str> {
DeleteBackupVaultLockConfigurationError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteBackupVaultLockConfigurationError {
pub fn new(
kind: DeleteBackupVaultLockConfigurationErrorKind,
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: DeleteBackupVaultLockConfigurationErrorKind::Unhandled(
crate::error::Unhandled::new(err.into()),
),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteBackupVaultLockConfigurationErrorKind::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,
DeleteBackupVaultLockConfigurationErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultLockConfigurationErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultLockConfigurationErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultLockConfigurationErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultLockConfigurationErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteBackupVaultLockConfigurationError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteBackupVaultLockConfigurationErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DeleteBackupVaultLockConfigurationErrorKind::InvalidRequestException(_inner) => {
Some(_inner)
}
DeleteBackupVaultLockConfigurationErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DeleteBackupVaultLockConfigurationErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
DeleteBackupVaultLockConfigurationErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
DeleteBackupVaultLockConfigurationErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteBackupVaultAccessPolicyError {
pub kind: DeleteBackupVaultAccessPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteBackupVaultAccessPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteBackupVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
source,
)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteBackupVaultAccessPolicyErrorKind {
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 DeleteBackupVaultAccessPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => {
_inner.fmt(f)
}
DeleteBackupVaultAccessPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteBackupVaultAccessPolicyError {
fn code(&self) -> Option<&str> {
DeleteBackupVaultAccessPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteBackupVaultAccessPolicyError {
pub fn new(
kind: DeleteBackupVaultAccessPolicyErrorKind,
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: DeleteBackupVaultAccessPolicyErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteBackupVaultAccessPolicyErrorKind::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,
DeleteBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteBackupVaultAccessPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteBackupVaultAccessPolicyErrorKind::InvalidParameterValueException(_inner) => {
Some(_inner)
}
DeleteBackupVaultAccessPolicyErrorKind::MissingParameterValueException(_inner) => {
Some(_inner)
}
DeleteBackupVaultAccessPolicyErrorKind::ResourceNotFoundException(_inner) => {
Some(_inner)
}
DeleteBackupVaultAccessPolicyErrorKind::ServiceUnavailableException(_inner) => {
Some(_inner)
}
DeleteBackupVaultAccessPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteBackupVaultError {
pub kind: DeleteBackupVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteBackupVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteBackupVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteBackupVaultErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteBackupVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteBackupVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteBackupVaultErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
DeleteBackupVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteBackupVaultErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteBackupVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteBackupVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteBackupVaultError {
fn code(&self) -> Option<&str> {
DeleteBackupVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteBackupVaultError {
pub fn new(kind: DeleteBackupVaultErrorKind, 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: DeleteBackupVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteBackupVaultErrorKind::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,
DeleteBackupVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteBackupVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteBackupVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteBackupVaultErrorKind::InvalidRequestException(_inner) => Some(_inner),
DeleteBackupVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteBackupVaultErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteBackupVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteBackupVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteBackupSelectionError {
pub kind: DeleteBackupSelectionErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteBackupSelectionError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteBackupSelectionErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteBackupSelectionErrorKind {
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 DeleteBackupSelectionError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteBackupSelectionErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteBackupSelectionErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteBackupSelectionErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteBackupSelectionErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteBackupSelectionErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteBackupSelectionError {
fn code(&self) -> Option<&str> {
DeleteBackupSelectionError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteBackupSelectionError {
pub fn new(kind: DeleteBackupSelectionErrorKind, 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: DeleteBackupSelectionErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteBackupSelectionErrorKind::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,
DeleteBackupSelectionErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupSelectionErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupSelectionErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupSelectionErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteBackupSelectionError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteBackupSelectionErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteBackupSelectionErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteBackupSelectionErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteBackupSelectionErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteBackupSelectionErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteBackupPlanError {
pub kind: DeleteBackupPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteBackupPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteBackupPlanErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidRequestException(crate::error::InvalidRequestException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteBackupPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteBackupPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
DeleteBackupPlanErrorKind::InvalidRequestException(_inner) => _inner.fmt(f),
DeleteBackupPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
DeleteBackupPlanErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteBackupPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
DeleteBackupPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteBackupPlanError {
fn code(&self) -> Option<&str> {
DeleteBackupPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteBackupPlanError {
pub fn new(kind: DeleteBackupPlanErrorKind, 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: DeleteBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteBackupPlanErrorKind::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,
DeleteBackupPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_request_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupPlanErrorKind::InvalidRequestException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupPlanErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
DeleteBackupPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for DeleteBackupPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteBackupPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
DeleteBackupPlanErrorKind::InvalidRequestException(_inner) => Some(_inner),
DeleteBackupPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
DeleteBackupPlanErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteBackupPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
DeleteBackupPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateReportPlanError {
pub kind: CreateReportPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateReportPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateReportPlanErrorKind {
AlreadyExistsException(crate::error::AlreadyExistsException),
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 CreateReportPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateReportPlanErrorKind::AlreadyExistsException(_inner) => _inner.fmt(f),
CreateReportPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateReportPlanErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateReportPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateReportPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateReportPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateReportPlanError {
fn code(&self) -> Option<&str> {
CreateReportPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateReportPlanError {
pub fn new(kind: CreateReportPlanErrorKind, 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: CreateReportPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateReportPlanErrorKind::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_already_exists_exception(&self) -> bool {
matches!(
&self.kind,
CreateReportPlanErrorKind::AlreadyExistsException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateReportPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateReportPlanErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateReportPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateReportPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateReportPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateReportPlanErrorKind::AlreadyExistsException(_inner) => Some(_inner),
CreateReportPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateReportPlanErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateReportPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateReportPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateReportPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateLegalHoldError {
pub kind: CreateLegalHoldErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateLegalHoldError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateLegalHoldErrorKind {
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 CreateLegalHoldError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateLegalHoldErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateLegalHoldErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateLegalHoldErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateLegalHoldErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateLegalHoldErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateLegalHoldError {
fn code(&self) -> Option<&str> {
CreateLegalHoldError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateLegalHoldError {
pub fn new(kind: CreateLegalHoldErrorKind, 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: CreateLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateLegalHoldErrorKind::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,
CreateLegalHoldErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateLegalHoldErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateLegalHoldErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateLegalHoldErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateLegalHoldError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateLegalHoldErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateLegalHoldErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateLegalHoldErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateLegalHoldErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateLegalHoldErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateFrameworkError {
pub kind: CreateFrameworkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateFrameworkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateFrameworkErrorKind {
AlreadyExistsException(crate::error::AlreadyExistsException),
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 CreateFrameworkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateFrameworkErrorKind::AlreadyExistsException(_inner) => _inner.fmt(f),
CreateFrameworkErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateFrameworkErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateFrameworkErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateFrameworkErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateFrameworkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateFrameworkError {
fn code(&self) -> Option<&str> {
CreateFrameworkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateFrameworkError {
pub fn new(kind: CreateFrameworkErrorKind, 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: CreateFrameworkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateFrameworkErrorKind::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_already_exists_exception(&self) -> bool {
matches!(
&self.kind,
CreateFrameworkErrorKind::AlreadyExistsException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateFrameworkErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateFrameworkErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateFrameworkErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateFrameworkErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateFrameworkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateFrameworkErrorKind::AlreadyExistsException(_inner) => Some(_inner),
CreateFrameworkErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateFrameworkErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateFrameworkErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateFrameworkErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateFrameworkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateBackupVaultError {
pub kind: CreateBackupVaultErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateBackupVaultError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateBackupVaultErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateBackupVaultErrorKind {
AlreadyExistsException(crate::error::AlreadyExistsException),
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 CreateBackupVaultError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateBackupVaultErrorKind::AlreadyExistsException(_inner) => _inner.fmt(f),
CreateBackupVaultErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateBackupVaultErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateBackupVaultErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateBackupVaultErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateBackupVaultErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateBackupVaultError {
fn code(&self) -> Option<&str> {
CreateBackupVaultError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateBackupVaultError {
pub fn new(kind: CreateBackupVaultErrorKind, 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: CreateBackupVaultErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateBackupVaultErrorKind::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_already_exists_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupVaultErrorKind::AlreadyExistsException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupVaultErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupVaultErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupVaultErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupVaultErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateBackupVaultError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateBackupVaultErrorKind::AlreadyExistsException(_inner) => Some(_inner),
CreateBackupVaultErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateBackupVaultErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateBackupVaultErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateBackupVaultErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateBackupVaultErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateBackupSelectionError {
pub kind: CreateBackupSelectionErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateBackupSelectionError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateBackupSelectionErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateBackupSelectionErrorKind {
AlreadyExistsException(crate::error::AlreadyExistsException),
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 CreateBackupSelectionError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateBackupSelectionErrorKind::AlreadyExistsException(_inner) => _inner.fmt(f),
CreateBackupSelectionErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateBackupSelectionErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateBackupSelectionErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateBackupSelectionErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateBackupSelectionErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateBackupSelectionError {
fn code(&self) -> Option<&str> {
CreateBackupSelectionError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateBackupSelectionError {
pub fn new(kind: CreateBackupSelectionErrorKind, 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: CreateBackupSelectionErrorKind::Unhandled(crate::error::Unhandled::new(
err.into(),
)),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateBackupSelectionErrorKind::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_already_exists_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupSelectionErrorKind::AlreadyExistsException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupSelectionErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupSelectionErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupSelectionErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupSelectionErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateBackupSelectionError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateBackupSelectionErrorKind::AlreadyExistsException(_inner) => Some(_inner),
CreateBackupSelectionErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateBackupSelectionErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateBackupSelectionErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateBackupSelectionErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateBackupSelectionErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateBackupPlanError {
pub kind: CreateBackupPlanErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateBackupPlanError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateBackupPlanErrorKind {
AlreadyExistsException(crate::error::AlreadyExistsException),
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 CreateBackupPlanError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateBackupPlanErrorKind::AlreadyExistsException(_inner) => _inner.fmt(f),
CreateBackupPlanErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CreateBackupPlanErrorKind::LimitExceededException(_inner) => _inner.fmt(f),
CreateBackupPlanErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CreateBackupPlanErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CreateBackupPlanErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateBackupPlanError {
fn code(&self) -> Option<&str> {
CreateBackupPlanError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateBackupPlanError {
pub fn new(kind: CreateBackupPlanErrorKind, 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: CreateBackupPlanErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateBackupPlanErrorKind::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_already_exists_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupPlanErrorKind::AlreadyExistsException(_)
)
}
pub fn is_invalid_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupPlanErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_limit_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupPlanErrorKind::LimitExceededException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupPlanErrorKind::MissingParameterValueException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CreateBackupPlanErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CreateBackupPlanError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateBackupPlanErrorKind::AlreadyExistsException(_inner) => Some(_inner),
CreateBackupPlanErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CreateBackupPlanErrorKind::LimitExceededException(_inner) => Some(_inner),
CreateBackupPlanErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CreateBackupPlanErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CreateBackupPlanErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CancelLegalHoldError {
pub kind: CancelLegalHoldErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CancelLegalHoldError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CancelLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CancelLegalHoldErrorKind {
InvalidParameterValueException(crate::error::InvalidParameterValueException),
InvalidResourceStateException(crate::error::InvalidResourceStateException),
MissingParameterValueException(crate::error::MissingParameterValueException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ServiceUnavailableException(crate::error::ServiceUnavailableException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for CancelLegalHoldError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CancelLegalHoldErrorKind::InvalidParameterValueException(_inner) => _inner.fmt(f),
CancelLegalHoldErrorKind::InvalidResourceStateException(_inner) => _inner.fmt(f),
CancelLegalHoldErrorKind::MissingParameterValueException(_inner) => _inner.fmt(f),
CancelLegalHoldErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
CancelLegalHoldErrorKind::ServiceUnavailableException(_inner) => _inner.fmt(f),
CancelLegalHoldErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CancelLegalHoldError {
fn code(&self) -> Option<&str> {
CancelLegalHoldError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CancelLegalHoldError {
pub fn new(kind: CancelLegalHoldErrorKind, 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: CancelLegalHoldErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CancelLegalHoldErrorKind::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,
CancelLegalHoldErrorKind::InvalidParameterValueException(_)
)
}
pub fn is_invalid_resource_state_exception(&self) -> bool {
matches!(
&self.kind,
CancelLegalHoldErrorKind::InvalidResourceStateException(_)
)
}
pub fn is_missing_parameter_value_exception(&self) -> bool {
matches!(
&self.kind,
CancelLegalHoldErrorKind::MissingParameterValueException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
CancelLegalHoldErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_service_unavailable_exception(&self) -> bool {
matches!(
&self.kind,
CancelLegalHoldErrorKind::ServiceUnavailableException(_)
)
}
}
impl std::error::Error for CancelLegalHoldError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CancelLegalHoldErrorKind::InvalidParameterValueException(_inner) => Some(_inner),
CancelLegalHoldErrorKind::InvalidResourceStateException(_inner) => Some(_inner),
CancelLegalHoldErrorKind::MissingParameterValueException(_inner) => Some(_inner),
CancelLegalHoldErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
CancelLegalHoldErrorKind::ServiceUnavailableException(_inner) => Some(_inner),
CancelLegalHoldErrorKind::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 _)
}
}