Struct Forwarded
pub struct Forwarded(/* private fields */);Available on crate features
http and std only.Expand description
Typed header wrapper for rama_net::forwarded::Forwarded;
Implementations§
§impl Forwarded
impl Forwarded
pub fn into_inner(self) -> Forwarded
pub fn into_inner(self) -> Forwarded
Return the inner Forwarded.
Methods from Deref<Target = Forwarded>§
pub fn client(
&self,
policy: &ForwardedSelectionPolicy,
) -> Option<&ForwardedElement>
Available on crate feature net only.
pub fn client( &self, policy: &ForwardedSelectionPolicy, ) -> Option<&ForwardedElement>
net only.The element describing the client, per policy.
pub fn prepend(
&mut self,
farther: impl IntoIterator<Item = ForwardedElement>,
) -> &mut Forwarded
Available on crate feature net only.
pub fn prepend( &mut self, farther: impl IntoIterator<Item = ForwardedElement>, ) -> &mut Forwarded
net only.Prepend elements written by hops farther away than this chain’s, keeping their order.
pub fn append(&mut self, element: ForwardedElement) -> &mut Forwarded
Available on crate feature net only.
pub fn append(&mut self, element: ForwardedElement) -> &mut Forwarded
net only.Append a ForwardedElement to this Forwarded context.
pub fn extend(
&mut self,
elements: impl IntoIterator<Item = ForwardedElement>,
) -> &mut Forwarded
Available on crate feature net only.
pub fn extend( &mut self, elements: impl IntoIterator<Item = ForwardedElement>, ) -> &mut Forwarded
net only.Extend this Forwarded context with the given ForwardedElements.
pub fn iter(&self) -> impl DoubleEndedIterator
Available on crate feature net only.
pub fn iter(&self) -> impl DoubleEndedIterator
net only.Iterate over the ForwardedElements in this Forwarded context.
Trait Implementations§
impl Eq for Forwarded
impl Extension for Forwarded
§impl ForwardHeader for Forwarded
impl ForwardHeader for Forwarded
§fn try_from_forwarded<'a, I>(input: I) -> Option<Forwarded>where
I: IntoIterator<Item = &'a ForwardedElement>,
fn try_from_forwarded<'a, I>(input: I) -> Option<Forwarded>where
I: IntoIterator<Item = &'a ForwardedElement>,
Try to convert the given iterator of
ForwardedElement into the header. Read more§impl HeaderDecode for Forwarded
impl HeaderDecode for Forwarded
§impl HeaderEncode for Forwarded
impl HeaderEncode for Forwarded
§fn encode<E>(&self, values: &mut E)where
E: Extend<HeaderValue>,
fn encode<E>(&self, values: &mut E)where
E: Extend<HeaderValue>,
Encode this type to a
HeaderValue, and add it to a container
which has HeaderValue type as each element. Read more§fn encode_to_value(&self) -> Option<HeaderValue>
fn encode_to_value(&self) -> Option<HeaderValue>
Encode this header to
HeaderValue. Read moreimpl HttpExtension for Forwarded
§impl IntoIterator for Forwarded
impl IntoIterator for Forwarded
impl StructuralPartialEq for Forwarded
§impl TypedHeader for Forwarded
impl TypedHeader for Forwarded
§fn name() -> &'static HeaderName
fn name() -> &'static HeaderName
The name of this header.
Auto Trait Implementations§
impl !Freeze for Forwarded
impl RefUnwindSafe for Forwarded
impl Send for Forwarded
impl Sync for Forwarded
impl Unpin for Forwarded
impl UnsafeUnpin for Forwarded
impl UnwindSafe for Forwarded
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
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§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> ⓘ
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 more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a rama_grpc::Request§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>
Create a new
Policy that returns Action::Follow only if self and other return
Action::Follow. Read more