pub enum DeliveryFailureKind {
InvalidReference(InvalidReference),
Undeliverable(UndeliverableReason),
Expired(ExpiredDelivery),
}Expand description
The kind of delivery failure.
Variants§
InvalidReference(InvalidReference)
The destination reference does not denote a valid recipient.
Undeliverable(UndeliverableReason)
The message could not be delivered for transport or receiver-lifecycle reasons.
Expired(ExpiredDelivery)
The message exceeded its TTL.
Implementations§
Source§impl DeliveryFailureKind
impl DeliveryFailureKind
Sourcepub fn is_invalid_reference(&self) -> bool
pub fn is_invalid_reference(&self) -> bool
Returns true if this is a DeliveryFailureKind::InvalidReference, otherwise false
Sourcepub fn as_invalid_reference_mut(&mut self) -> Option<&mut InvalidReference>
pub fn as_invalid_reference_mut(&mut self) -> Option<&mut InvalidReference>
Optionally returns mutable references to the inner fields if this is a DeliveryFailureKind::InvalidReference, otherwise None
Sourcepub fn as_invalid_reference(&self) -> Option<&InvalidReference>
pub fn as_invalid_reference(&self) -> Option<&InvalidReference>
Optionally returns references to the inner fields if this is a DeliveryFailureKind::InvalidReference, otherwise None
Sourcepub fn into_invalid_reference(self) -> Result<InvalidReference, Self>
pub fn into_invalid_reference(self) -> Result<InvalidReference, Self>
Returns the inner fields if this is a DeliveryFailureKind::InvalidReference, otherwise returns back the enum in the Err case of the result
Sourcepub fn is_undeliverable(&self) -> bool
pub fn is_undeliverable(&self) -> bool
Returns true if this is a DeliveryFailureKind::Undeliverable, otherwise false
Sourcepub fn as_undeliverable_mut(&mut self) -> Option<&mut UndeliverableReason>
pub fn as_undeliverable_mut(&mut self) -> Option<&mut UndeliverableReason>
Optionally returns mutable references to the inner fields if this is a DeliveryFailureKind::Undeliverable, otherwise None
Sourcepub fn as_undeliverable(&self) -> Option<&UndeliverableReason>
pub fn as_undeliverable(&self) -> Option<&UndeliverableReason>
Optionally returns references to the inner fields if this is a DeliveryFailureKind::Undeliverable, otherwise None
Sourcepub fn into_undeliverable(self) -> Result<UndeliverableReason, Self>
pub fn into_undeliverable(self) -> Result<UndeliverableReason, Self>
Returns the inner fields if this is a DeliveryFailureKind::Undeliverable, otherwise returns back the enum in the Err case of the result
Sourcepub fn is_expired(&self) -> bool
pub fn is_expired(&self) -> bool
Returns true if this is a DeliveryFailureKind::Expired, otherwise false
Sourcepub fn as_expired_mut(&mut self) -> Option<&mut ExpiredDelivery>
pub fn as_expired_mut(&mut self) -> Option<&mut ExpiredDelivery>
Optionally returns mutable references to the inner fields if this is a DeliveryFailureKind::Expired, otherwise None
Sourcepub fn as_expired(&self) -> Option<&ExpiredDelivery>
pub fn as_expired(&self) -> Option<&ExpiredDelivery>
Optionally returns references to the inner fields if this is a DeliveryFailureKind::Expired, otherwise None
Sourcepub fn into_expired(self) -> Result<ExpiredDelivery, Self>
pub fn into_expired(self) -> Result<ExpiredDelivery, Self>
Returns the inner fields if this is a DeliveryFailureKind::Expired, otherwise returns back the enum in the Err case of the result
Trait Implementations§
Source§impl Clone for DeliveryFailureKind
impl Clone for DeliveryFailureKind
Source§fn clone(&self) -> DeliveryFailureKind
fn clone(&self) -> DeliveryFailureKind
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DeliveryFailureKind
impl Debug for DeliveryFailureKind
Source§impl<'de> Deserialize<'de> for DeliveryFailureKind
impl<'de> Deserialize<'de> for DeliveryFailureKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Display for DeliveryFailureKind
impl Display for DeliveryFailureKind
Source§impl Error for DeliveryFailureKind
impl Error for DeliveryFailureKind
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
use the Display impl or to_string()
Source§impl From<ExpiredDelivery> for DeliveryFailureKind
impl From<ExpiredDelivery> for DeliveryFailureKind
Source§fn from(source: ExpiredDelivery) -> Self
fn from(source: ExpiredDelivery) -> Self
Source§impl From<InvalidReference> for DeliveryFailureKind
impl From<InvalidReference> for DeliveryFailureKind
Source§fn from(source: InvalidReference) -> Self
fn from(source: InvalidReference) -> Self
Source§impl From<UndeliverableReason> for DeliveryFailureKind
impl From<UndeliverableReason> for DeliveryFailureKind
Source§fn from(source: UndeliverableReason) -> Self
fn from(source: UndeliverableReason) -> Self
Source§impl Named for DeliveryFailureKind
impl Named for DeliveryFailureKind
Source§fn typename() -> &'static str
fn typename() -> &'static str
Source§fn typehash() -> u64
fn typehash() -> u64
Source§fn arm(&self) -> Option<&'static str>
fn arm(&self) -> Option<&'static str>
Source§impl PartialEq for DeliveryFailureKind
impl PartialEq for DeliveryFailureKind
Source§impl Serialize for DeliveryFailureKind
impl Serialize for DeliveryFailureKind
impl Eq for DeliveryFailureKind
impl StructuralPartialEq for DeliveryFailureKind
Auto Trait Implementations§
impl Freeze for DeliveryFailureKind
impl RefUnwindSafe for DeliveryFailureKind
impl Send for DeliveryFailureKind
impl Sync for DeliveryFailureKind
impl Unpin for DeliveryFailureKind
impl UnsafeUnpin for DeliveryFailureKind
impl UnwindSafe for DeliveryFailureKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].