#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateLinkError {
pub kind: UpdateLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for UpdateLinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: UpdateLinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateLinkErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for UpdateLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateLinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
UpdateLinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
UpdateLinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
UpdateLinkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
UpdateLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateLinkError {
fn code(&self) -> Option<&str> {
UpdateLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl UpdateLinkError {
pub fn new(kind: UpdateLinkErrorKind, 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: UpdateLinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateLinkErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, UpdateLinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
UpdateLinkErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
UpdateLinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UpdateLinkErrorKind::ResourceNotFoundException(_)
)
}
}
impl std::error::Error for UpdateLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateLinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
UpdateLinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
UpdateLinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
UpdateLinkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UpdateLinkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ResourceNotFoundException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
#[doc(hidden)]
pub amzn_error_type: std::option::Option<std::string::String>,
}
impl ResourceNotFoundException {
pub fn amzn_error_type(&self) -> std::option::Option<&str> {
self.amzn_error_type.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_1) = &self.message {
{
write!(f, ": {}", inner_1)?;
}
}
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) message: std::option::Option<std::string::String>,
pub(crate) amzn_error_type: std::option::Option<std::string::String>,
}
impl Builder {
#[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 amzn_error_type(mut self, input: impl Into<std::string::String>) -> Self {
self.amzn_error_type = Some(input.into());
self
}
pub fn set_amzn_error_type(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.amzn_error_type = input;
self
}
pub fn build(self) -> crate::error::ResourceNotFoundException {
crate::error::ResourceNotFoundException {
message: self.message,
amzn_error_type: self.amzn_error_type,
}
}
}
}
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 MissingRequiredParameterException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
#[doc(hidden)]
pub amzn_error_type: std::option::Option<std::string::String>,
}
impl MissingRequiredParameterException {
pub fn amzn_error_type(&self) -> std::option::Option<&str> {
self.amzn_error_type.as_deref()
}
}
impl MissingRequiredParameterException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for MissingRequiredParameterException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MissingRequiredParameterException")?;
if let Some(inner_2) = &self.message {
{
write!(f, ": {}", inner_2)?;
}
}
Ok(())
}
}
impl std::error::Error for MissingRequiredParameterException {}
pub mod missing_required_parameter_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) amzn_error_type: std::option::Option<std::string::String>,
}
impl Builder {
#[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 amzn_error_type(mut self, input: impl Into<std::string::String>) -> Self {
self.amzn_error_type = Some(input.into());
self
}
pub fn set_amzn_error_type(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.amzn_error_type = input;
self
}
pub fn build(self) -> crate::error::MissingRequiredParameterException {
crate::error::MissingRequiredParameterException {
message: self.message,
amzn_error_type: self.amzn_error_type,
}
}
}
}
impl MissingRequiredParameterException {
pub fn builder() -> crate::error::missing_required_parameter_exception::Builder {
crate::error::missing_required_parameter_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InvalidParameterException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
#[doc(hidden)]
pub amzn_error_type: std::option::Option<std::string::String>,
}
impl InvalidParameterException {
pub fn amzn_error_type(&self) -> std::option::Option<&str> {
self.amzn_error_type.as_deref()
}
}
impl InvalidParameterException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InvalidParameterException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InvalidParameterException")?;
if let Some(inner_3) = &self.message {
{
write!(f, ": {}", inner_3)?;
}
}
Ok(())
}
}
impl std::error::Error for InvalidParameterException {}
pub mod invalid_parameter_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) amzn_error_type: std::option::Option<std::string::String>,
}
impl Builder {
#[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 amzn_error_type(mut self, input: impl Into<std::string::String>) -> Self {
self.amzn_error_type = Some(input.into());
self
}
pub fn set_amzn_error_type(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.amzn_error_type = input;
self
}
pub fn build(self) -> crate::error::InvalidParameterException {
crate::error::InvalidParameterException {
message: self.message,
amzn_error_type: self.amzn_error_type,
}
}
}
}
impl InvalidParameterException {
pub fn builder() -> crate::error::invalid_parameter_exception::Builder {
crate::error::invalid_parameter_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InternalServiceFault {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
#[doc(hidden)]
pub amzn_error_type: std::option::Option<std::string::String>,
}
impl InternalServiceFault {
pub fn amzn_error_type(&self) -> std::option::Option<&str> {
self.amzn_error_type.as_deref()
}
}
impl InternalServiceFault {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InternalServiceFault {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InternalServiceFault")?;
if let Some(inner_4) = &self.message {
{
write!(f, ": {}", inner_4)?;
}
}
Ok(())
}
}
impl std::error::Error for InternalServiceFault {}
pub mod internal_service_fault {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) amzn_error_type: std::option::Option<std::string::String>,
}
impl Builder {
#[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 amzn_error_type(mut self, input: impl Into<std::string::String>) -> Self {
self.amzn_error_type = Some(input.into());
self
}
pub fn set_amzn_error_type(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.amzn_error_type = input;
self
}
pub fn build(self) -> crate::error::InternalServiceFault {
crate::error::InternalServiceFault {
message: self.message,
amzn_error_type: self.amzn_error_type,
}
}
}
}
impl InternalServiceFault {
pub fn builder() -> crate::error::internal_service_fault::Builder {
crate::error::internal_service_fault::Builder::default()
}
}
#[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 {
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ValidationException(crate::error::ValidationException),
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::ResourceNotFoundException(_inner) => _inner.fmt(f),
UntagResourceErrorKind::ValidationException(_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_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
UntagResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_validation_exception(&self) -> bool {
matches!(&self.kind, UntagResourceErrorKind::ValidationException(_))
}
}
impl std::error::Error for UntagResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UntagResourceErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
UntagResourceErrorKind::ValidationException(_inner) => Some(_inner),
UntagResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ValidationException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl ValidationException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for ValidationException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ValidationException")?;
if let Some(inner_5) = &self.message {
{
write!(f, ": {}", inner_5)?;
}
}
Ok(())
}
}
impl std::error::Error for ValidationException {}
pub mod validation_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::ValidationException {
crate::error::ValidationException {
message: self.message,
}
}
}
}
impl ValidationException {
pub fn builder() -> crate::error::validation_exception::Builder {
crate::error::validation_exception::Builder::default()
}
}
#[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 {
ResourceNotFoundException(crate::error::ResourceNotFoundException),
TooManyTagsException(crate::error::TooManyTagsException),
ValidationException(crate::error::ValidationException),
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::ResourceNotFoundException(_inner) => _inner.fmt(f),
TagResourceErrorKind::TooManyTagsException(_inner) => _inner.fmt(f),
TagResourceErrorKind::ValidationException(_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_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
TagResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_too_many_tags_exception(&self) -> bool {
matches!(&self.kind, TagResourceErrorKind::TooManyTagsException(_))
}
pub fn is_validation_exception(&self) -> bool {
matches!(&self.kind, TagResourceErrorKind::ValidationException(_))
}
}
impl std::error::Error for TagResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
TagResourceErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
TagResourceErrorKind::TooManyTagsException(_inner) => Some(_inner),
TagResourceErrorKind::ValidationException(_inner) => Some(_inner),
TagResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct TooManyTagsException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl TooManyTagsException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for TooManyTagsException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "TooManyTagsException")?;
if let Some(inner_6) = &self.message {
{
write!(f, ": {}", inner_6)?;
}
}
Ok(())
}
}
impl std::error::Error for TooManyTagsException {}
pub mod too_many_tags_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn build(self) -> crate::error::TooManyTagsException {
crate::error::TooManyTagsException {
message: self.message,
}
}
}
}
impl TooManyTagsException {
pub fn builder() -> crate::error::too_many_tags_exception::Builder {
crate::error::too_many_tags_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PutSinkPolicyError {
pub kind: PutSinkPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for PutSinkPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: PutSinkPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PutSinkPolicyErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for PutSinkPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PutSinkPolicyErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
PutSinkPolicyErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
PutSinkPolicyErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
PutSinkPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
PutSinkPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PutSinkPolicyError {
fn code(&self) -> Option<&str> {
PutSinkPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl PutSinkPolicyError {
pub fn new(kind: PutSinkPolicyErrorKind, 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: PutSinkPolicyErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PutSinkPolicyErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, PutSinkPolicyErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
PutSinkPolicyErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
PutSinkPolicyErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
PutSinkPolicyErrorKind::ResourceNotFoundException(_)
)
}
}
impl std::error::Error for PutSinkPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PutSinkPolicyErrorKind::InternalServiceFault(_inner) => Some(_inner),
PutSinkPolicyErrorKind::InvalidParameterException(_inner) => Some(_inner),
PutSinkPolicyErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
PutSinkPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
PutSinkPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListTagsForResourceError {
pub kind: ListTagsForResourceErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListTagsForResourceError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListTagsForResourceErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListTagsForResourceErrorKind {
ResourceNotFoundException(crate::error::ResourceNotFoundException),
ValidationException(crate::error::ValidationException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListTagsForResourceError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListTagsForResourceErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListTagsForResourceErrorKind::ValidationException(_inner) => _inner.fmt(f),
ListTagsForResourceErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListTagsForResourceError {
fn code(&self) -> Option<&str> {
ListTagsForResourceError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListTagsForResourceError {
pub fn new(kind: ListTagsForResourceErrorKind, 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: ListTagsForResourceErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListTagsForResourceErrorKind::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_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsForResourceErrorKind::ResourceNotFoundException(_)
)
}
pub fn is_validation_exception(&self) -> bool {
matches!(
&self.kind,
ListTagsForResourceErrorKind::ValidationException(_)
)
}
}
impl std::error::Error for ListTagsForResourceError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListTagsForResourceErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListTagsForResourceErrorKind::ValidationException(_inner) => Some(_inner),
ListTagsForResourceErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListSinksError {
pub kind: ListSinksErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListSinksError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListSinksErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListSinksErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListSinksError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListSinksErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
ListSinksErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
ListSinksErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListSinksErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListSinksError {
fn code(&self) -> Option<&str> {
ListSinksError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListSinksError {
pub fn new(kind: ListSinksErrorKind, 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: ListSinksErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListSinksErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, ListSinksErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(&self.kind, ListSinksErrorKind::InvalidParameterException(_))
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, ListSinksErrorKind::ResourceNotFoundException(_))
}
}
impl std::error::Error for ListSinksError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListSinksErrorKind::InternalServiceFault(_inner) => Some(_inner),
ListSinksErrorKind::InvalidParameterException(_inner) => Some(_inner),
ListSinksErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListSinksErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListLinksError {
pub kind: ListLinksErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListLinksError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListLinksErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListLinksErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListLinksError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListLinksErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
ListLinksErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
ListLinksErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListLinksErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListLinksError {
fn code(&self) -> Option<&str> {
ListLinksError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListLinksError {
pub fn new(kind: ListLinksErrorKind, 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: ListLinksErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListLinksErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, ListLinksErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(&self.kind, ListLinksErrorKind::InvalidParameterException(_))
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, ListLinksErrorKind::ResourceNotFoundException(_))
}
}
impl std::error::Error for ListLinksError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListLinksErrorKind::InternalServiceFault(_inner) => Some(_inner),
ListLinksErrorKind::InvalidParameterException(_inner) => Some(_inner),
ListLinksErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListLinksErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListAttachedLinksError {
pub kind: ListAttachedLinksErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for ListAttachedLinksError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: ListAttachedLinksErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListAttachedLinksErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for ListAttachedLinksError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListAttachedLinksErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
ListAttachedLinksErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
ListAttachedLinksErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
ListAttachedLinksErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
ListAttachedLinksErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListAttachedLinksError {
fn code(&self) -> Option<&str> {
ListAttachedLinksError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl ListAttachedLinksError {
pub fn new(kind: ListAttachedLinksErrorKind, 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: ListAttachedLinksErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListAttachedLinksErrorKind::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_internal_service_fault(&self) -> bool {
matches!(
&self.kind,
ListAttachedLinksErrorKind::InternalServiceFault(_)
)
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
ListAttachedLinksErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
ListAttachedLinksErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
ListAttachedLinksErrorKind::ResourceNotFoundException(_)
)
}
}
impl std::error::Error for ListAttachedLinksError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListAttachedLinksErrorKind::InternalServiceFault(_inner) => Some(_inner),
ListAttachedLinksErrorKind::InvalidParameterException(_inner) => Some(_inner),
ListAttachedLinksErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
ListAttachedLinksErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
ListAttachedLinksErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetSinkPolicyError {
pub kind: GetSinkPolicyErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetSinkPolicyError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetSinkPolicyErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetSinkPolicyErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetSinkPolicyError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetSinkPolicyErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
GetSinkPolicyErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
GetSinkPolicyErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
GetSinkPolicyErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetSinkPolicyErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetSinkPolicyError {
fn code(&self) -> Option<&str> {
GetSinkPolicyError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetSinkPolicyError {
pub fn new(kind: GetSinkPolicyErrorKind, 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: GetSinkPolicyErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetSinkPolicyErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, GetSinkPolicyErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
GetSinkPolicyErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
GetSinkPolicyErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
GetSinkPolicyErrorKind::ResourceNotFoundException(_)
)
}
}
impl std::error::Error for GetSinkPolicyError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetSinkPolicyErrorKind::InternalServiceFault(_inner) => Some(_inner),
GetSinkPolicyErrorKind::InvalidParameterException(_inner) => Some(_inner),
GetSinkPolicyErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
GetSinkPolicyErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetSinkPolicyErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetSinkError {
pub kind: GetSinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetSinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetSinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetSinkErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetSinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetSinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
GetSinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
GetSinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
GetSinkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetSinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetSinkError {
fn code(&self) -> Option<&str> {
GetSinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetSinkError {
pub fn new(kind: GetSinkErrorKind, 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: GetSinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetSinkErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, GetSinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(&self.kind, GetSinkErrorKind::InvalidParameterException(_))
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
GetSinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, GetSinkErrorKind::ResourceNotFoundException(_))
}
}
impl std::error::Error for GetSinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetSinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
GetSinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
GetSinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
GetSinkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetSinkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetLinkError {
pub kind: GetLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for GetLinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: GetLinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetLinkErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for GetLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetLinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
GetLinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
GetLinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
GetLinkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
GetLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetLinkError {
fn code(&self) -> Option<&str> {
GetLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl GetLinkError {
pub fn new(kind: GetLinkErrorKind, 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: GetLinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetLinkErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, GetLinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(&self.kind, GetLinkErrorKind::InvalidParameterException(_))
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
GetLinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(&self.kind, GetLinkErrorKind::ResourceNotFoundException(_))
}
}
impl std::error::Error for GetLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetLinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
GetLinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
GetLinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
GetLinkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
GetLinkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteSinkError {
pub kind: DeleteSinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteSinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteSinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteSinkErrorKind {
ConflictException(crate::error::ConflictException),
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteSinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteSinkErrorKind::ConflictException(_inner) => _inner.fmt(f),
DeleteSinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
DeleteSinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
DeleteSinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
DeleteSinkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteSinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteSinkError {
fn code(&self) -> Option<&str> {
DeleteSinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteSinkError {
pub fn new(kind: DeleteSinkErrorKind, 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: DeleteSinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteSinkErrorKind::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, DeleteSinkErrorKind::ConflictException(_))
}
pub fn is_internal_service_fault(&self) -> bool {
matches!(&self.kind, DeleteSinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
DeleteSinkErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
DeleteSinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteSinkErrorKind::ResourceNotFoundException(_)
)
}
}
impl std::error::Error for DeleteSinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteSinkErrorKind::ConflictException(_inner) => Some(_inner),
DeleteSinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
DeleteSinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
DeleteSinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
DeleteSinkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteSinkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ConflictException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
#[doc(hidden)]
pub amzn_error_type: std::option::Option<std::string::String>,
}
impl ConflictException {
pub fn amzn_error_type(&self) -> std::option::Option<&str> {
self.amzn_error_type.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_7) = &self.message {
{
write!(f, ": {}", inner_7)?;
}
}
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) message: std::option::Option<std::string::String>,
pub(crate) amzn_error_type: std::option::Option<std::string::String>,
}
impl Builder {
#[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 amzn_error_type(mut self, input: impl Into<std::string::String>) -> Self {
self.amzn_error_type = Some(input.into());
self
}
pub fn set_amzn_error_type(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.amzn_error_type = input;
self
}
pub fn build(self) -> crate::error::ConflictException {
crate::error::ConflictException {
message: self.message,
amzn_error_type: self.amzn_error_type,
}
}
}
}
impl ConflictException {
pub fn builder() -> crate::error::conflict_exception::Builder {
crate::error::conflict_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct DeleteLinkError {
pub kind: DeleteLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for DeleteLinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: DeleteLinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum DeleteLinkErrorKind {
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ResourceNotFoundException(crate::error::ResourceNotFoundException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for DeleteLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
DeleteLinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
DeleteLinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
DeleteLinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
DeleteLinkErrorKind::ResourceNotFoundException(_inner) => _inner.fmt(f),
DeleteLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for DeleteLinkError {
fn code(&self) -> Option<&str> {
DeleteLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl DeleteLinkError {
pub fn new(kind: DeleteLinkErrorKind, 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: DeleteLinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: DeleteLinkErrorKind::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_internal_service_fault(&self) -> bool {
matches!(&self.kind, DeleteLinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
DeleteLinkErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
DeleteLinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_resource_not_found_exception(&self) -> bool {
matches!(
&self.kind,
DeleteLinkErrorKind::ResourceNotFoundException(_)
)
}
}
impl std::error::Error for DeleteLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
DeleteLinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
DeleteLinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
DeleteLinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
DeleteLinkErrorKind::ResourceNotFoundException(_inner) => Some(_inner),
DeleteLinkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateSinkError {
pub kind: CreateSinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateSinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateSinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateSinkErrorKind {
ConflictException(crate::error::ConflictException),
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ServiceQuotaExceededException(crate::error::ServiceQuotaExceededException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for CreateSinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateSinkErrorKind::ConflictException(_inner) => _inner.fmt(f),
CreateSinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
CreateSinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
CreateSinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
CreateSinkErrorKind::ServiceQuotaExceededException(_inner) => _inner.fmt(f),
CreateSinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateSinkError {
fn code(&self) -> Option<&str> {
CreateSinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateSinkError {
pub fn new(kind: CreateSinkErrorKind, 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: CreateSinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateSinkErrorKind::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, CreateSinkErrorKind::ConflictException(_))
}
pub fn is_internal_service_fault(&self) -> bool {
matches!(&self.kind, CreateSinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
CreateSinkErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
CreateSinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_service_quota_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateSinkErrorKind::ServiceQuotaExceededException(_)
)
}
}
impl std::error::Error for CreateSinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateSinkErrorKind::ConflictException(_inner) => Some(_inner),
CreateSinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
CreateSinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
CreateSinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
CreateSinkErrorKind::ServiceQuotaExceededException(_inner) => Some(_inner),
CreateSinkErrorKind::Unhandled(_inner) => Some(_inner),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ServiceQuotaExceededException {
#[allow(missing_docs)] #[doc(hidden)]
pub message: std::option::Option<std::string::String>,
#[doc(hidden)]
pub amzn_error_type: std::option::Option<std::string::String>,
}
impl ServiceQuotaExceededException {
pub fn amzn_error_type(&self) -> std::option::Option<&str> {
self.amzn_error_type.as_deref()
}
}
impl ServiceQuotaExceededException {
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for ServiceQuotaExceededException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ServiceQuotaExceededException")?;
if let Some(inner_8) = &self.message {
{
write!(f, ": {}", inner_8)?;
}
}
Ok(())
}
}
impl std::error::Error for ServiceQuotaExceededException {}
pub mod service_quota_exceeded_exception {
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) amzn_error_type: std::option::Option<std::string::String>,
}
impl Builder {
#[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 amzn_error_type(mut self, input: impl Into<std::string::String>) -> Self {
self.amzn_error_type = Some(input.into());
self
}
pub fn set_amzn_error_type(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.amzn_error_type = input;
self
}
pub fn build(self) -> crate::error::ServiceQuotaExceededException {
crate::error::ServiceQuotaExceededException {
message: self.message,
amzn_error_type: self.amzn_error_type,
}
}
}
}
impl ServiceQuotaExceededException {
pub fn builder() -> crate::error::service_quota_exceeded_exception::Builder {
crate::error::service_quota_exceeded_exception::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CreateLinkError {
pub kind: CreateLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
impl aws_smithy_http::result::CreateUnhandledError for CreateLinkError {
fn create_unhandled_error(source: Box<dyn std::error::Error + Send + Sync + 'static>) -> Self {
Self {
kind: CreateLinkErrorKind::Unhandled(crate::error::Unhandled::new(source)),
meta: Default::default(),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CreateLinkErrorKind {
ConflictException(crate::error::ConflictException),
InternalServiceFault(crate::error::InternalServiceFault),
InvalidParameterException(crate::error::InvalidParameterException),
MissingRequiredParameterException(crate::error::MissingRequiredParameterException),
ServiceQuotaExceededException(crate::error::ServiceQuotaExceededException),
Unhandled(crate::error::Unhandled),
}
impl std::fmt::Display for CreateLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CreateLinkErrorKind::ConflictException(_inner) => _inner.fmt(f),
CreateLinkErrorKind::InternalServiceFault(_inner) => _inner.fmt(f),
CreateLinkErrorKind::InvalidParameterException(_inner) => _inner.fmt(f),
CreateLinkErrorKind::MissingRequiredParameterException(_inner) => _inner.fmt(f),
CreateLinkErrorKind::ServiceQuotaExceededException(_inner) => _inner.fmt(f),
CreateLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CreateLinkError {
fn code(&self) -> Option<&str> {
CreateLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
None
}
}
impl CreateLinkError {
pub fn new(kind: CreateLinkErrorKind, 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: CreateLinkErrorKind::Unhandled(crate::error::Unhandled::new(err.into())),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CreateLinkErrorKind::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, CreateLinkErrorKind::ConflictException(_))
}
pub fn is_internal_service_fault(&self) -> bool {
matches!(&self.kind, CreateLinkErrorKind::InternalServiceFault(_))
}
pub fn is_invalid_parameter_exception(&self) -> bool {
matches!(
&self.kind,
CreateLinkErrorKind::InvalidParameterException(_)
)
}
pub fn is_missing_required_parameter_exception(&self) -> bool {
matches!(
&self.kind,
CreateLinkErrorKind::MissingRequiredParameterException(_)
)
}
pub fn is_service_quota_exceeded_exception(&self) -> bool {
matches!(
&self.kind,
CreateLinkErrorKind::ServiceQuotaExceededException(_)
)
}
}
impl std::error::Error for CreateLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CreateLinkErrorKind::ConflictException(_inner) => Some(_inner),
CreateLinkErrorKind::InternalServiceFault(_inner) => Some(_inner),
CreateLinkErrorKind::InvalidParameterException(_inner) => Some(_inner),
CreateLinkErrorKind::MissingRequiredParameterException(_inner) => Some(_inner),
CreateLinkErrorKind::ServiceQuotaExceededException(_inner) => Some(_inner),
CreateLinkErrorKind::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 _)
}
}