pub enum ProtocolError<E> {
    TransportError(E),
    Stopped,
    PeerClosed,
    PeerClosedWithEpitaph(i32),
    InvalidMessageHeader(DecodeError),
    InvalidEpitaphBody(DecodeError),
    UnrequestedResponse {
        txid: u32,
    },
    InvalidResponseOrdinal {
        expected: u64,
        actual: u64,
    },
    UnknownOrdinal(u64),
    InvalidMessage {
        ordinal: u64,
        error: DecodeError,
    },
}Expand description
Errors that can be produced by FIDL clients and servers.
Variants§
TransportError(E)
The underlying transport encountered an error.
Stopped
The underlying transport was stopped gracefully.
PeerClosed
The underlying transport was closed by the peer.
PeerClosedWithEpitaph(i32)
The underlying transport was closed by the peer with an epitaph.
InvalidMessageHeader(DecodeError)
The client or server received a message with an invalid protocol header.
InvalidEpitaphBody(DecodeError)
The client received an epitaph with an invalid body.
UnrequestedResponse
The client received a response for a two-way message which it did not send.
InvalidResponseOrdinal
The client received a response with the wrong ordinal for the two-way message.
Fields
UnknownOrdinal(u64)
The client or server received a message with an unknown ordinal, and the strictness of the method or openness of the protocol does not allow for unknown ordinals in that situation.
InvalidMessage
The client or server failed to decode a message as the type indicated by the ordinal.
Fields
error: DecodeErrorThe error encountered while attempting to decode the message.
Trait Implementations§
Source§impl<E: Clone> Clone for ProtocolError<E>
 
impl<E: Clone> Clone for ProtocolError<E>
Source§fn clone(&self) -> ProtocolError<E>
 
fn clone(&self) -> ProtocolError<E>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
source. Read more