#[non_exhaustive]pub enum ModifyDBProxyError {
DbProxyAlreadyExistsFault(DbProxyAlreadyExistsFault),
DbProxyNotFoundFault(DbProxyNotFoundFault),
InvalidDbProxyStateFault(InvalidDbProxyStateFault),
Unhandled(Unhandled),
}
Expand description
Error type for the ModifyDBProxyError
operation.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
DbProxyAlreadyExistsFault(DbProxyAlreadyExistsFault)
The specified proxy name must be unique for all proxies owned by your Amazon Web Services account in the specified Amazon Web Services Region.
DbProxyNotFoundFault(DbProxyNotFoundFault)
The specified proxy name doesn't correspond to a proxy owned by your Amazon Web Services account in the specified Amazon Web Services Region.
InvalidDbProxyStateFault(InvalidDbProxyStateFault)
The requested operation can't be performed while the proxy is in this state.
Unhandled(Unhandled)
Unhandled
directly is not forwards compatible. Instead, match using a variable wildcard pattern and check .code()
:
err if err.code() == Some("SpecificExceptionCode") => { /* handle the error */ }
See ProvideErrorMetadata
for what information is available for the error.An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
Implementations§
source§impl ModifyDBProxyError
impl ModifyDBProxyError
sourcepub fn unhandled(err: impl Into<Box<dyn Error + Send + Sync + 'static>>) -> Self
pub fn unhandled(err: impl Into<Box<dyn Error + Send + Sync + 'static>>) -> Self
Creates the ModifyDBProxyError::Unhandled
variant from any error type.
sourcepub fn generic(err: ErrorMetadata) -> Self
pub fn generic(err: ErrorMetadata) -> Self
Creates the ModifyDBProxyError::Unhandled
variant from an ErrorMetadata
.
sourcepub fn meta(&self) -> &ErrorMetadata
pub fn meta(&self) -> &ErrorMetadata
Returns error metadata, which includes the error code, message, request ID, and potentially additional information.
sourcepub fn is_db_proxy_already_exists_fault(&self) -> bool
pub fn is_db_proxy_already_exists_fault(&self) -> bool
Returns true
if the error kind is ModifyDBProxyError::DbProxyAlreadyExistsFault
.
sourcepub fn is_db_proxy_not_found_fault(&self) -> bool
pub fn is_db_proxy_not_found_fault(&self) -> bool
Returns true
if the error kind is ModifyDBProxyError::DbProxyNotFoundFault
.
sourcepub fn is_invalid_db_proxy_state_fault(&self) -> bool
pub fn is_invalid_db_proxy_state_fault(&self) -> bool
Returns true
if the error kind is ModifyDBProxyError::InvalidDbProxyStateFault
.
Trait Implementations§
source§impl CreateUnhandledError for ModifyDBProxyError
impl CreateUnhandledError for ModifyDBProxyError
source§fn create_unhandled_error(
source: Box<dyn Error + Send + Sync + 'static>,
meta: Option<ErrorMetadata>
) -> Self
fn create_unhandled_error( source: Box<dyn Error + Send + Sync + 'static>, meta: Option<ErrorMetadata> ) -> Self
source
and error metadata.source§impl Debug for ModifyDBProxyError
impl Debug for ModifyDBProxyError
source§impl Display for ModifyDBProxyError
impl Display for ModifyDBProxyError
source§impl Error for ModifyDBProxyError
impl Error for ModifyDBProxyError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
source§impl From<ModifyDBProxyError> for Error
impl From<ModifyDBProxyError> for Error
source§fn from(err: ModifyDBProxyError) -> Self
fn from(err: ModifyDBProxyError) -> Self
source§impl ProvideErrorMetadata for ModifyDBProxyError
impl ProvideErrorMetadata for ModifyDBProxyError
source§fn meta(&self) -> &ErrorMetadata
fn meta(&self) -> &ErrorMetadata
source§impl RequestId for ModifyDBProxyError
impl RequestId for ModifyDBProxyError
source§fn request_id(&self) -> Option<&str>
fn request_id(&self) -> Option<&str>
None
if the service could not be reached.