Struct HttpHeadersProfile
pub struct HttpHeadersProfile {
pub navigate: Http1HeaderMap,
pub fetch: Option<Http1HeaderMap>,
pub xhr: Option<Http1HeaderMap>,
pub form: Option<Http1HeaderMap>,
pub ws: Option<Http1HeaderMap>,
}
Fields§
The headers to be used for navigation requests.
A navigation request is the regular request that a user-agent makes automatically or on behalf of the user, but that is not triggered directly by a script.
fetch: Option<Http1HeaderMap>
The headers to be used for fetch requests.
A fetch request is a request made by a script to retrieve a resource from a server,
using the fetch
API.
In case the user-agent does not support the fetch
API,
then it is recommended to try to use the xhr
headers,
and as a final fallback use the navigate
headers.
xhr: Option<Http1HeaderMap>
The headers to be used for XMLHttpRequest requests.
An XMLHttpRequest
is a request made by a script to retrieve a resource from a server.
In case the user-agent does not support the [XMLHttpRequest
][XMLHttpRequest
] API,
then it is recommended to try to use the fetch
headers,
and as a final fallback use the navigate
headers.
form: Option<Http1HeaderMap>
The headers to be used for form submissions.
A form submission is a request made by a script to submit a form to a server.
In case the user-agent does not support forms (e.g. because it does not handle html forms),
then it is recommended to try to use the fetch
headers and any fallbacks that the latter may have.
ws: Option<Http1HeaderMap>
The headers to be used for WebSocket handshake requests.
No UA profile is used for http headers
- in case WS is detected
- and no profile is defined
Trait Implementations§
§impl Debug for HttpHeadersProfile
impl Debug for HttpHeadersProfile
§impl<'de> Deserialize<'de> for HttpHeadersProfile
impl<'de> Deserialize<'de> for HttpHeadersProfile
§fn deserialize<__D>(
__deserializer: __D,
) -> Result<HttpHeadersProfile, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<HttpHeadersProfile, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
§impl Serialize for HttpHeadersProfile
impl Serialize for HttpHeadersProfile
§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for HttpHeadersProfile
impl RefUnwindSafe for HttpHeadersProfile
impl Send for HttpHeadersProfile
impl Sync for HttpHeadersProfile
impl Unpin for HttpHeadersProfile
impl UnwindSafe for HttpHeadersProfile
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
§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> ⓘ
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§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§fn and<P, B, E>(self, other: P) -> And<T, P>
fn and<P, B, E>(self, other: P) -> And<T, P>
Policy
that returns Action::Follow
only if self
and other
return
Action::Follow
. Read more