pub enum FileDumpMsg {
    Request {
        requester_device: DeviceID,
        file_type: FileType,
        name: BString,
    },
    Header {
        sender_device: DeviceID,
        file_type: FileType,
        length: u32,
        name: BString,
    },
    Packet {
        running_count: u8,
        data: Vec<u8>,
    },
}
Expand description

Used to transmit general file data. Used by UniversalNonRealTimeMsg.

Variants

Request

Fields

requester_device: DeviceID
file_type: FileType
name: BString

Request that the file with name be sent.

Header

Fields

sender_device: DeviceID
file_type: FileType
length: u32

Actual (un-encoded) file length, 28 bits (0-2684354561)

name: BString

The header of the file about to be sent.

Packet

Fields

running_count: u8

Running packet count, 0-127. Wraps back to 0

data: Vec<u8>

At most 112 bytes (full 8 bits may be used)

A packet of the file being sent.

Use FileDumpMsg::packet to construct

Implementations

Construct a packet of up to 112 (full) bytes. num is the number of this packet.

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.