[][src]Trait s4::S4

pub trait S4 {
    fn download_to_file<F>(
        &self,
        source: GetObjectRequest,
        target: F
    ) -> S4Result<GetObjectOutput>
    where
        F: AsRef<Path>
;
fn upload_from_file<F>(
        &self,
        source: F,
        target: PutObjectRequest
    ) -> S4Result<PutObjectOutput>
    where
        F: AsRef<Path>
;
fn upload_from_file_multipart<F>(
        &self,
        source: F,
        target: &PutObjectRequest,
        part_size: usize
    ) -> S4Result<CompleteMultipartUploadOutput>
    where
        F: AsRef<Path>
;
fn download<W>(
        &self,
        source: GetObjectRequest,
        target: &mut W
    ) -> S4Result<GetObjectOutput>
    where
        W: Write
;
fn upload<R>(
        &self,
        source: &mut R,
        target: PutObjectRequest
    ) -> S4Result<PutObjectOutput>
    where
        R: Read
;
fn upload_multipart<R>(
        &self,
        source: &mut R,
        target: &PutObjectRequest,
        part_size: usize
    ) -> S4Result<CompleteMultipartUploadOutput>
    where
        R: Read
;
fn iter_objects(&self, bucket: &str) -> ObjectIter;
fn iter_objects_with_prefix(&self, bucket: &str, prefix: &str) -> ObjectIter;
fn iter_get_objects(&self, bucket: &str) -> GetObjectIter;
fn iter_get_objects_with_prefix(
        &self,
        bucket: &str,
        prefix: &str
    ) -> GetObjectIter; }

Required methods

fn download_to_file<F>(
    &self,
    source: GetObjectRequest,
    target: F
) -> S4Result<GetObjectOutput> where
    F: AsRef<Path>, 

Get object and write it to file target

fn upload_from_file<F>(
    &self,
    source: F,
    target: PutObjectRequest
) -> S4Result<PutObjectOutput> where
    F: AsRef<Path>, 

Upload content of file to S3

Caveats

The current implementation is incomplete. For now, the following limitation applies:

  • The full content of source is copied into memory.

fn upload_from_file_multipart<F>(
    &self,
    source: F,
    target: &PutObjectRequest,
    part_size: usize
) -> S4Result<CompleteMultipartUploadOutput> where
    F: AsRef<Path>, 

Upload content of file to S3 using multi-part upload

Caveats

The current implementation is incomplete. For now, the following limitation applies:

  • The full content of a part is copied into memory.

fn download<W>(
    &self,
    source: GetObjectRequest,
    target: &mut W
) -> S4Result<GetObjectOutput> where
    W: Write

Get object and write it to target

fn upload<R>(
    &self,
    source: &mut R,
    target: PutObjectRequest
) -> S4Result<PutObjectOutput> where
    R: Read

Read source and upload it to S3

Caveats

The current implementation is incomplete. For now, the following limitation applies:

  • The full content of source is copied into memory.

fn upload_multipart<R>(
    &self,
    source: &mut R,
    target: &PutObjectRequest,
    part_size: usize
) -> S4Result<CompleteMultipartUploadOutput> where
    R: Read

Read source and upload it to S3 using multi-part upload

Caveats

The current implementation is incomplete. For now, the following limitation applies:

  • The full content of a part is copied into memory.

fn iter_objects(&self, bucket: &str) -> ObjectIter

Iterator over all objects

Objects are lexicographically sorted by their key.

fn iter_objects_with_prefix(&self, bucket: &str, prefix: &str) -> ObjectIter

Iterator over objects with given prefix

Objects are lexicographically sorted by their key.

fn iter_get_objects(&self, bucket: &str) -> GetObjectIter

Iterator over all objects; fetching objects as needed

Objects are lexicographically sorted by their key.

fn iter_get_objects_with_prefix(
    &self,
    bucket: &str,
    prefix: &str
) -> GetObjectIter

Iterator over objects with given prefix; fetching objects as needed

Objects are lexicographically sorted by their key.

Loading content...

Implementations on Foreign Types

impl<'a> S4 for S3Client[src]

Loading content...

Implementors

Loading content...