pub struct ClientIp(pub IpAddr);Expand description
Extracts the best-effort client IP address for the current request.
Tuple Fields§
§0: IpAddrTrait Implementations§
Source§impl<S> FromRequestParts<S> for ClientIp
impl<S> FromRequestParts<S> for ClientIp
Source§type Rejection = ClientIpMissing
type Rejection = ClientIpMissing
If the extractor fails it’ll use this “rejection” type. A rejection is
a kind of error that can be converted into a response.
Auto Trait Implementations§
impl Freeze for ClientIp
impl RefUnwindSafe for ClientIp
impl Send for ClientIp
impl Sync for ClientIp
impl Unpin for ClientIp
impl UnsafeUnpin for ClientIp
impl UnwindSafe for ClientIp
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<S, T> FromRequest<S, ViaParts> for T
impl<S, T> FromRequest<S, ViaParts> for T
Source§type Rejection = <T as FromRequestParts<S>>::Rejection
type Rejection = <T as FromRequestParts<S>>::Rejection
If the extractor fails it’ll use this “rejection” type. A rejection is
a kind of error that can be converted into a response.