Enum tari_comms_dht::outbound::SendMessageResponse[][src]

pub enum SendMessageResponse {
    Queued(MessageSendStates),
    Failed(SendFailure),
    PendingDiscovery(Receiver<SendMessageResponse>),
}

Variants

Returns the message tags which are queued for sending. These tags will be used in a subsequent OutboundEvent to indicate if the message succeeded/failed to send

Failed(SendFailure)

A failure occurred when sending

PendingDiscovery(Receiver<SendMessageResponse>)

DHT Discovery has been initiated. The caller may wait on the receiver to find out of the message was sent. NOTE: DHT discovery could take minutes (determined by `DhtConfig::discovery_request_timeout)

Implementations

impl SendMessageResponse[src]

pub async fn resolve(self) -> Result<MessageSendStates, SendFailure>[src]

Returns the result of a send message request. A SendMessageResponse::Queued(n) will resolve immediately returning Ok(n) or Err(SendFailure::NoMessagesSent). A SendMessageResponse::Failed will resolve immediately returning a Err(SendFailure). If DHT discovery is initiated, this will resolve once discovery has completed, either succeeding or failing.

Trait Implementations

impl Debug for SendMessageResponse[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T, U> Cast<U> for T where
    U: FromCast<T>, 

impl<T> From<T> for T[src]

impl<T> FromBits<T> for T

impl<T> FromCast<T> for T

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> IntoBits<U> for T where
    U: FromBits<T>, 

impl<T> IntoSql for T[src]

impl<T> SafeBorrow<T> for T where
    T: ?Sized

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,