[][src]Enum file_protocol::Message

pub enum Message {
    Sync(u32String),
    Metadata(u32Stringu32),
    ReceiveChunk(u32Stringu32Vec<u8>),
    ACK(u32String),
    NAK(u32StringOption<Vec<(u32, u32)>>),
    ReqReceive(u32StringStringOption<u32>),
    ReqTransmit(u32String),
    SuccessReceive(u32String),
    SuccessTransmit(u32Stringu32Option<u32>),
    Failure(u32String),
    Cleanup(u32Option<String>),
}

File protocol message types

Variants

TODO: Decide whether or not to keep this

Receiver should prepare a new temporary storage folder with the specified metadata

File data chunk message

Receiver has successfully gotten all data chunks of the requested file

Receiver is missing the specified file data chunks

(Client Only) Message requesting the recipient to receive the specified file

(Client Only) Message requesting the recipient to transmit the specified file

(Server Only) Recipient has successfully processed a request to receive a file

(Server Only) Recipient has successfully prepared to transmit a file

(Server Only) The transmit or receive request has failed to be completed

Request Cleanup of either whole storage directory or individual file's storage

Trait Implementations

impl Clone for Message
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Eq for Message
[src]

impl PartialEq<Message> for Message
[src]

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

This method tests for !=.

impl Debug for Message
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for Message

impl Sync for Message

Blanket Implementations

impl<T> From for T
[src]

Performs the conversion.

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

Performs the conversion.

impl<T> ToOwned for T where
    T: Clone
[src]

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

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

Immutably borrows from an owned value. Read more

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

Mutably borrows from an owned value. Read more

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

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

🔬 This is a nightly-only experimental API. (get_type_id)

this method will likely be replaced by an associated static

Gets the TypeId of self. Read more