Skip to main content
pub struct FnUploadListener<F1, F2, F3>
where
    F1: Fn(Vec<OperationResult>) + Send + Sync,
    F2: Fn(OperationResult) + Send + Sync,
    F3: Fn(OperationResult) + Send + Sync,
/* private fields */

A simple upload listener that wraps callback functions.

This provides a convenient way to create listeners using closures without implementing the full trait.

Example

Implementations

Source

impl<F1, F2, F3>FnUploadListener<F1, F2, F3>

Source

pub fn new(on_multi_part_complete: F1, on_part: F2, on_full: F3) -> Self

Creates a new function-based upload listener.

Trait Implementations

Source

impl<F1, F2, F3>FileUploadListener for FnUploadListener<F1, F2, F3>

Called when all parts of a multi-part upload have been completed. Read more
Called whenever a single part of a multi-part upload has been completed. Read more
Called for each batch of whole files sent in one request, as it finishes, and for each file that could not be read to be sent. Read more
Called when a multi-part upload was aborted because one of its stages failed after it had been initiated. Read more