pub struct NamedFileBuilder { /* private fields */ }Expand description
Builder for build NamedFile.
Implementations§
Source§impl NamedFileBuilder
impl NamedFileBuilder
Sourcepub fn attached_name<T>(self, attached_name: T) -> NamedFileBuilder
pub fn attached_name<T>(self, attached_name: T) -> NamedFileBuilder
Sets attached filename and returns Self.
Sourcepub fn disposition_type<T>(self, disposition_type: T) -> NamedFileBuilder
pub fn disposition_type<T>(self, disposition_type: T) -> NamedFileBuilder
Sets disposition encoding and returns Self.
Sourcepub fn disable_content_disposition(&mut self)
pub fn disable_content_disposition(&mut self)
Disable Content-Disposition header.
By default Content-Disposition` header is enabled.
Sourcepub fn content_type(self, content_type: Mime) -> NamedFileBuilder
pub fn content_type(self, content_type: Mime) -> NamedFileBuilder
Sets content type and returns Self.
Sourcepub fn content_encoding<T>(self, content_encoding: T) -> NamedFileBuilder
pub fn content_encoding<T>(self, content_encoding: T) -> NamedFileBuilder
Sets content encoding and returns Self.
Sourcepub fn buffer_size(self, buffer_size: u64) -> NamedFileBuilder
pub fn buffer_size(self, buffer_size: u64) -> NamedFileBuilder
Sets buffer size and returns Self.
Sourcepub fn use_etag(self, value: bool) -> NamedFileBuilder
pub fn use_etag(self, value: bool) -> NamedFileBuilder
Specifies whether to use ETag or not.
Default is true.
Sourcepub fn use_last_modified(self, value: bool) -> NamedFileBuilder
pub fn use_last_modified(self, value: bool) -> NamedFileBuilder
Specifies whether to use Last-Modified or not.
Default is true.
Trait Implementations§
Source§impl Clone for NamedFileBuilder
impl Clone for NamedFileBuilder
Source§fn clone(&self) -> NamedFileBuilder
fn clone(&self) -> NamedFileBuilder
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for NamedFileBuilder
impl RefUnwindSafe for NamedFileBuilder
impl Send for NamedFileBuilder
impl Sync for NamedFileBuilder
impl Unpin for NamedFileBuilder
impl UnwindSafe for NamedFileBuilder
Blanket Implementations§
Source§impl<Data> ApiSuccessResponse for Data
impl<Data> ApiSuccessResponse for Data
fn api_response<Meta>(self, meta: Option<Meta>) -> ApiResponse<Self, Meta>
fn api_response_without_meta<Meta>(self) -> ApiResponse<Self, Meta>
fn api_response_with_meta<Meta>(self, meta: Meta) -> ApiResponse<Self, Meta>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> FutureTraceExt for Twhere
T: FutureExt,
impl<T> FutureTraceExt for Twhere
T: FutureExt,
Source§fn with_current_context_span(self, otel_span: Span) -> WithContext<Self> ⓘ
fn with_current_context_span(self, otel_span: Span) -> WithContext<Self> ⓘ
Pass the span of opentelemetry to the current context of tracing.
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::Request