[][src]Enum yew::services::reader::FileChunk

pub enum FileChunk {
    Started {
        name: String,
    },
    DataChunk {
        data: Vec<u8>,
        progress: f32,
    },
    Finished,
}

Struct that represents a chunk of a file.

Variants

Started

Reading of chunks started. Equals 0% progress.

Fields of Started

name: String

Name of loaded file.

DataChunk

The next data chunk that read. Also provides a progress value.

Fields of DataChunk

data: Vec<u8>

The chunk of binary data.

progress: f32

The progress value in interval: 0 < progress <= 1.

Finished

Reading of chunks finished. Equals 100% progress.

Trait Implementations

impl Clone for FileChunk[src]

impl Debug for FileChunk[src]

Auto Trait Implementations

Blanket Implementations

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

impl<T> Any for T where
    T: Any
[src]

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

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

impl<T> CloneAny for T where
    T: Clone + Any
[src]

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

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

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

type Owned = T

The resulting type after obtaining ownership.

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.