[−][src]Enum proxy_protocol::ProxyHeader
The PROXY header.
Variants
Fields of Version1
family: ProxyAddressFamily
If this is Unspec, all the other values are zeroed. In any other case, the rest of the values have proper values.
source: IpAddr
destination: IpAddr
source_port: u16
destination_port: u16
Fields of Version2
command: ProxyCommand
transport_protocol: ProxyTransportProtocol
address: ProxyAddress
source_port: Option<u16>
destination_port: Option<u16>
Methods
impl ProxyHeader
[src]
pub fn encode(self) -> Result<BytesMut, EncodingError>
[src]
pub fn decode(buf: &mut Bytes) -> Result<Self, DecodingError>
[src]
Trait Implementations
impl Clone for ProxyHeader
[src]
fn clone(&self) -> ProxyHeader
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for ProxyHeader
[src]
impl Eq for ProxyHeader
[src]
impl PartialEq<ProxyHeader> for ProxyHeader
[src]
fn eq(&self, other: &ProxyHeader) -> bool
[src]
fn ne(&self, other: &ProxyHeader) -> bool
[src]
impl StructuralEq for ProxyHeader
[src]
impl StructuralPartialEq for ProxyHeader
[src]
Auto Trait Implementations
impl RefUnwindSafe for ProxyHeader
impl Send for ProxyHeader
impl Sync for ProxyHeader
impl Unpin for ProxyHeader
impl UnwindSafe for ProxyHeader
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,