pub struct DownloadRequest<'a, T: ?Sized = Bucket> {
pub key: String,
pub version: Option<String>,
pub range: Option<ByteRange>,
/* private fields */
}Expand description
The download Bucket::download makes: await it for the object’s
contents.
Fields§
§key: String§version: Option<String>§range: Option<ByteRange>Implementations§
Source§impl<'a, T: ?Sized> DownloadRequest<'a, T>
impl<'a, T: ?Sized> DownloadRequest<'a, T>
Sourcepub fn version(self, version: impl Into<String>) -> Self
pub fn version(self, version: impl Into<String>) -> Self
On this version of the object, in a versioned bucket, rather than the current one.
Sourcepub fn range(self, range: impl RangeBounds<u64>) -> Self
pub fn range(self, range: impl RangeBounds<u64>) -> Self
Only these bytes of the object: 1024..1280, 1024.., ..=99.
An empty range is Error::InvalidArgument.
Trait Implementations§
Source§impl<'a> IntoFuture for DownloadRequest<'a, Bucket>
impl<'a> IntoFuture for DownloadRequest<'a, Bucket>
Source§type IntoFuture = Pin<Box<dyn Future<Output = <DownloadRequest<'a> as IntoFuture>::Output> + Send + 'a>>
type IntoFuture = Pin<Box<dyn Future<Output = <DownloadRequest<'a> as IntoFuture>::Output> + Send + 'a>>
Which kind of future are we turning this into?
Source§fn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
Source§impl<'a, T: Downloader + ?Sized> IntoFuture for DownloadRequest<'a, T>
impl<'a, T: Downloader + ?Sized> IntoFuture for DownloadRequest<'a, T>
Source§type IntoFuture = Pin<Box<dyn Future<Output = <DownloadRequest<'a, T> as IntoFuture>::Output> + Send + 'a>>
type IntoFuture = Pin<Box<dyn Future<Output = <DownloadRequest<'a, T> as IntoFuture>::Output> + Send + 'a>>
Which kind of future are we turning this into?
Source§fn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
Auto Trait Implementations§
impl<'a, T> Forget for DownloadRequest<'a, T>where
T: ?Sized,
impl<'a, T> Freeze for DownloadRequest<'a, T>
impl<'a, T> Move for DownloadRequest<'a, T>where
T: ?Sized,
impl<'a, T> RefUnwindSafe for DownloadRequest<'a, T>
impl<'a, T> Send for DownloadRequest<'a, T>
impl<'a, T> Sync for DownloadRequest<'a, T>
impl<'a, T> Unpin for DownloadRequest<'a, T>
impl<'a, T> UnsafeUnpin for DownloadRequest<'a, T>
impl<'a, T> UnwindSafe for DownloadRequest<'a, T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
Source§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::RequestCreates a shared type from an unshared type.