pub struct RequestFmt<Headers, Uri> { /* private fields */ }
Expand description
Allows the modification the requests URIs Display
and headers
Debug
to accommodate sensitivity.
This enjoys MakeFmt
for &HeaderMap
and &Uri
.
Implementations§
source§impl RequestFmt<MakeIdentity, MakeUri<MakeIdentity, MakeIdentity>>
impl RequestFmt<MakeIdentity, MakeUri<MakeIdentity, MakeIdentity>>
sourcepub fn new() -> Self
pub fn new() -> Self
Constructs a new RequestFmt
with no redactions.
source§impl<Header, Uri> RequestFmt<Header, Uri>
impl<Header, Uri> RequestFmt<Header, Uri>
sourcepub fn header<F>(self, headers: F) -> RequestFmt<MakeHeaders<F>, Uri>
pub fn header<F>(self, headers: F) -> RequestFmt<MakeHeaders<F>, Uri>
Marks parts of headers as sensitive using a closure.
See SensitiveHeaders
for more info.
source§impl<Header, P, Q> RequestFmt<Header, MakeUri<P, Q>>
impl<Header, P, Q> RequestFmt<Header, MakeUri<P, Q>>
sourcepub fn label<F>(
self,
label_marker: F,
greedy_label: Option<GreedyLabel>,
) -> RequestFmt<Header, MakeUri<MakeLabel<F>, Q>>
pub fn label<F>( self, label_marker: F, greedy_label: Option<GreedyLabel>, ) -> RequestFmt<Header, MakeUri<MakeLabel<F>, Q>>
Marks parts of the URI as sensitive.
See Label
for more info.
Trait Implementations§
source§impl<Headers: Clone, Uri: Clone> Clone for RequestFmt<Headers, Uri>
impl<Headers: Clone, Uri: Clone> Clone for RequestFmt<Headers, Uri>
source§fn clone(&self) -> RequestFmt<Headers, Uri>
fn clone(&self) -> RequestFmt<Headers, Uri>
Returns a copy 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 moresource§impl<Headers, Uri> Debug for RequestFmt<Headers, Uri>
impl<Headers, Uri> Debug for RequestFmt<Headers, Uri>
source§impl<'a, Headers, Uri> MakeFmt<&'a HeaderMap> for RequestFmt<Headers, Uri>
impl<'a, Headers, Uri> MakeFmt<&'a HeaderMap> for RequestFmt<Headers, Uri>
source§impl<'a, Headers, Uri> MakeFmt<&'a Uri> for RequestFmt<Headers, Uri>
impl<'a, Headers, Uri> MakeFmt<&'a Uri> for RequestFmt<Headers, Uri>
Auto Trait Implementations§
impl<Headers, Uri> Freeze for RequestFmt<Headers, Uri>
impl<Headers, Uri> RefUnwindSafe for RequestFmt<Headers, Uri>where
Headers: RefUnwindSafe,
Uri: RefUnwindSafe,
impl<Headers, Uri> Send for RequestFmt<Headers, Uri>
impl<Headers, Uri> Sync for RequestFmt<Headers, Uri>
impl<Headers, Uri> Unpin for RequestFmt<Headers, Uri>
impl<Headers, Uri> UnwindSafe for RequestFmt<Headers, Uri>where
Headers: UnwindSafe,
Uri: UnwindSafe,
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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.