Enum eventstore_tcp::raw::RawMessage [] [src]

pub enum RawMessage<'a> {
    HeartbeatRequest,
    HeartbeatResponse,
    Ping,
    Pong,
    WriteEvents(WriteEvents<'a>),
    WriteEventsCompleted(WriteEventsCompleted<'a>),
    DeleteStream(DeleteStream<'a>),
    DeleteStreamCompleted(DeleteStreamCompleted<'a>),
    ReadEvent(ReadEvent<'a>),
    ReadEventCompleted(ReadEventCompleted<'a>),
    ReadStreamEvents(ReadDirectionReadStreamEvents<'a>),
    ReadStreamEventsCompleted(ReadDirectionReadStreamEventsCompleted<'a>),
    ReadAllEvents(ReadDirectionReadAllEvents),
    ReadAllEventsCompleted(ReadDirectionReadAllEventsCompleted<'a>),
    BadRequest(BadRequestPayload<'a>),
    NotHandled(NotHandled<'a>),
    Authenticate,
    Authenticated,
    NotAuthenticated(NotAuthenticatedPayload<'a>),
    Unsupported(u8Cow<'a, [u8]>),
}

Enumeration much like the adapted::AdaptedMessage for all the messages in the protocol.

Variants

Requests heartbeat from the other side. Unsure if clients or server sends these.

Response to a heartbeat request.

Ping request, similar to heartbeat.

Ping response.

Append to stream request

Append to stream response, which can fail for a number of reasons

Request to delete a stream

Response to previous stream deletion request

Request to read a single event from a stream

Response to a single event read

Request to read a stream from a point forward or backward

Response to a stream read in given direction

Request to read a stream of all events from a position forward or backward

Response to a read all in given direction

Request was not understood. Please open an issue!

Correlated request was not handled. This is the likely response to requests where require_master is true, but the connected endpoint is not master and cannot reach it.

Request to authenticate attached credentials.

Positive authentication response. The credentials used to Authenticate previously can be used in successive requests.

Negative authentication response, or response to any sent request for which used authentication was not accepted. May contain a reason.

Placeholder for a discriminator and the undecoded bytes

Methods

impl<'a> RawMessage<'a>
[src]

Attempt to convert a raw message into an adapted one

Turns possibly borrowed value of self into one that owns all of it's data.

Decodes the message from the buffer without any cloning.

Encodes the message into the given writer.

Returns the protocol discriminator value for the variant

Trait Implementations

impl<'a> Debug for RawMessage<'a>
[src]

Formats the value using the given formatter.

impl<'a> PartialEq for RawMessage<'a>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl<'a> Clone for RawMessage<'a>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<'a> From<BadRequestPayload<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<NotAuthenticatedPayload<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<WriteEvents<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<WriteEventsCompleted<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<DeleteStream<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<DeleteStreamCompleted<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<ReadEvent<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<ReadEventCompleted<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<NotHandled<'a>> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<(ReadDirection, ReadStreamEvents<'a>)> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<(ReadDirection, ReadStreamEventsCompleted<'a>)> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<(ReadDirection, ReadAllEvents)> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<(ReadDirection, ReadAllEventsCompleted<'a>)> for RawMessage<'a>
[src]

Performs the conversion.

impl<'a> From<(u8, Cow<'a, [u8]>)> for RawMessage<'a>
[src]

Performs the conversion.