pub struct Builder { /* private fields */ }
Implementations§
Source§impl Builder
impl Builder
Sourcepub fn grace_period(self, grace_period: Duration) -> Self
pub fn grace_period(self, grace_period: Duration) -> Self
Set the grace period for stalled stream protection.
Sourcepub fn set_grace_period(&mut self, grace_period: Option<Duration>) -> &mut Self
pub fn set_grace_period(&mut self, grace_period: Option<Duration>) -> &mut Self
Set the grace period for stalled stream protection.
Sourcepub fn is_enabled(self, enabled: bool) -> Self
pub fn is_enabled(self, enabled: bool) -> Self
Set whether stalled stream protection is enabled for both uploads and downloads.
Sourcepub fn set_is_enabled(&mut self, enabled: Option<bool>) -> &mut Self
pub fn set_is_enabled(&mut self, enabled: Option<bool>) -> &mut Self
Set whether stalled stream protection is enabled for both uploads and downloads.
Sourcepub fn upload_enabled(self, enabled: bool) -> Self
pub fn upload_enabled(self, enabled: bool) -> Self
Set whether stalled stream protection is enabled for upload streams.
Sourcepub fn set_upload_enabled(&mut self, enabled: Option<bool>) -> &mut Self
pub fn set_upload_enabled(&mut self, enabled: Option<bool>) -> &mut Self
Set whether stalled stream protection is enabled for upload streams.
Sourcepub fn download_enabled(self, enabled: bool) -> Self
pub fn download_enabled(self, enabled: bool) -> Self
Set whether stalled stream protection is enabled for download streams.
Sourcepub fn set_download_enabled(&mut self, enabled: Option<bool>) -> &mut Self
pub fn set_download_enabled(&mut self, enabled: Option<bool>) -> &mut Self
Set whether stalled stream protection is enabled for download streams.
Sourcepub fn build(self) -> StalledStreamProtectionConfig
pub fn build(self) -> StalledStreamProtectionConfig
Build the config.
Trait Implementations§
Source§impl From<StalledStreamProtectionConfig> for Builder
impl From<StalledStreamProtectionConfig> for Builder
Source§fn from(config: StalledStreamProtectionConfig) -> Self
fn from(config: StalledStreamProtectionConfig) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Builder
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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 moreCreates a shared type from an unshared type.