#[non_exhaustive]pub struct StatusCodesBuilder { /* private fields */ }
Expand description
A builder for StatusCodes
.
Implementations§
source§impl StatusCodesBuilder
impl StatusCodesBuilder
sourcepub fn status2xx(self, input: i32) -> Self
pub fn status2xx(self, input: i32) -> Self
The percentage of requests over the last 10 seconds that resulted in a 2xx (200, 201, etc.) status code.
sourcepub fn set_status2xx(self, input: Option<i32>) -> Self
pub fn set_status2xx(self, input: Option<i32>) -> Self
The percentage of requests over the last 10 seconds that resulted in a 2xx (200, 201, etc.) status code.
sourcepub fn get_status2xx(&self) -> &Option<i32>
pub fn get_status2xx(&self) -> &Option<i32>
The percentage of requests over the last 10 seconds that resulted in a 2xx (200, 201, etc.) status code.
sourcepub fn status3xx(self, input: i32) -> Self
pub fn status3xx(self, input: i32) -> Self
The percentage of requests over the last 10 seconds that resulted in a 3xx (300, 301, etc.) status code.
sourcepub fn set_status3xx(self, input: Option<i32>) -> Self
pub fn set_status3xx(self, input: Option<i32>) -> Self
The percentage of requests over the last 10 seconds that resulted in a 3xx (300, 301, etc.) status code.
sourcepub fn get_status3xx(&self) -> &Option<i32>
pub fn get_status3xx(&self) -> &Option<i32>
The percentage of requests over the last 10 seconds that resulted in a 3xx (300, 301, etc.) status code.
sourcepub fn status4xx(self, input: i32) -> Self
pub fn status4xx(self, input: i32) -> Self
The percentage of requests over the last 10 seconds that resulted in a 4xx (400, 401, etc.) status code.
sourcepub fn set_status4xx(self, input: Option<i32>) -> Self
pub fn set_status4xx(self, input: Option<i32>) -> Self
The percentage of requests over the last 10 seconds that resulted in a 4xx (400, 401, etc.) status code.
sourcepub fn get_status4xx(&self) -> &Option<i32>
pub fn get_status4xx(&self) -> &Option<i32>
The percentage of requests over the last 10 seconds that resulted in a 4xx (400, 401, etc.) status code.
sourcepub fn status5xx(self, input: i32) -> Self
pub fn status5xx(self, input: i32) -> Self
The percentage of requests over the last 10 seconds that resulted in a 5xx (500, 501, etc.) status code.
sourcepub fn set_status5xx(self, input: Option<i32>) -> Self
pub fn set_status5xx(self, input: Option<i32>) -> Self
The percentage of requests over the last 10 seconds that resulted in a 5xx (500, 501, etc.) status code.
sourcepub fn get_status5xx(&self) -> &Option<i32>
pub fn get_status5xx(&self) -> &Option<i32>
The percentage of requests over the last 10 seconds that resulted in a 5xx (500, 501, etc.) status code.
sourcepub fn build(self) -> StatusCodes
pub fn build(self) -> StatusCodes
Consumes the builder and constructs a StatusCodes
.
Trait Implementations§
source§impl Clone for StatusCodesBuilder
impl Clone for StatusCodesBuilder
source§fn clone(&self) -> StatusCodesBuilder
fn clone(&self) -> StatusCodesBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for StatusCodesBuilder
impl Debug for StatusCodesBuilder
source§impl Default for StatusCodesBuilder
impl Default for StatusCodesBuilder
source§fn default() -> StatusCodesBuilder
fn default() -> StatusCodesBuilder
source§impl PartialEq for StatusCodesBuilder
impl PartialEq for StatusCodesBuilder
impl StructuralPartialEq for StatusCodesBuilder
Auto Trait Implementations§
impl Freeze for StatusCodesBuilder
impl RefUnwindSafe for StatusCodesBuilder
impl Send for StatusCodesBuilder
impl Sync for StatusCodesBuilder
impl Unpin for StatusCodesBuilder
impl UnwindSafe for StatusCodesBuilder
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
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)
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>
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>
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 more