pub trait ForwardHeader: Header + IntoIterator<Item = ForwardedElement> {
// Required method
fn try_from_forwarded<'a, I>(into_it: I) -> Option<Self>
where I: IntoIterator<Item = &'a ForwardedElement>,
Self: Sized;
}
Expand description
A trait for types headers that is used by middleware which supports headers that can be converted into and from Forward data.
Required Methods§
Sourcefn try_from_forwarded<'a, I>(into_it: I) -> Option<Self>
fn try_from_forwarded<'a, I>(into_it: I) -> Option<Self>
Try to convert the given iterator of ForwardedElement
into the header.
None
is returned if the conversion fails.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.