Enum net_traits::ReferrerPolicy
source · pub enum ReferrerPolicy {
EmptyString,
NoReferrer,
NoReferrerWhenDowngrade,
Origin,
SameOrigin,
OriginWhenCrossOrigin,
UnsafeUrl,
StrictOrigin,
StrictOriginWhenCrossOrigin,
}
Expand description
Policies for providing a referrer header for a request
Variants§
EmptyString
“”
NoReferrer
“no-referrer”
NoReferrerWhenDowngrade
“no-referrer-when-downgrade”
Origin
“origin”
SameOrigin
“same-origin”
OriginWhenCrossOrigin
“origin-when-cross-origin”
UnsafeUrl
“unsafe-url”
StrictOrigin
“strict-origin”
StrictOriginWhenCrossOrigin
“strict-origin-when-cross-origin”
Trait Implementations§
source§impl Clone for ReferrerPolicy
impl Clone for ReferrerPolicy
source§fn clone(&self) -> ReferrerPolicy
fn clone(&self) -> ReferrerPolicy
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 Debug for ReferrerPolicy
impl Debug for ReferrerPolicy
source§impl Default for ReferrerPolicy
impl Default for ReferrerPolicy
source§fn default() -> ReferrerPolicy
fn default() -> ReferrerPolicy
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for ReferrerPolicy
impl<'de> Deserialize<'de> for ReferrerPolicy
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for ReferrerPolicy
impl Display for ReferrerPolicy
source§impl From<Option<ReferrerPolicy>> for ReferrerPolicy
impl From<Option<ReferrerPolicy>> for ReferrerPolicy
source§fn from(header: Option<ReferrerPolicyHeader>) -> Self
fn from(header: Option<ReferrerPolicyHeader>) -> Self
Converts to this type from the input type.
source§impl From<ReferrerPolicy> for ReferrerPolicy
impl From<ReferrerPolicy> for ReferrerPolicy
source§fn from(referrer_policy: ReferrerPolicy) -> Self
fn from(referrer_policy: ReferrerPolicy) -> Self
Converts to this type from the input type.
source§impl MallocSizeOf for ReferrerPolicy
impl MallocSizeOf for ReferrerPolicy
source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Measure the heap usage of all descendant heap-allocated structures, but
not the space taken up by the value itself.
source§impl PartialEq for ReferrerPolicy
impl PartialEq for ReferrerPolicy
source§fn eq(&self, other: &ReferrerPolicy) -> bool
fn eq(&self, other: &ReferrerPolicy) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for ReferrerPolicy
impl Serialize for ReferrerPolicy
impl Copy for ReferrerPolicy
impl StructuralPartialEq for ReferrerPolicy
Auto Trait Implementations§
impl Freeze for ReferrerPolicy
impl RefUnwindSafe for ReferrerPolicy
impl Send for ReferrerPolicy
impl Sync for ReferrerPolicy
impl Unpin for ReferrerPolicy
impl UnwindSafe for ReferrerPolicy
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> 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> Pointable for T
impl<T> Pointable for T
source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian()
.