pub trait IpIntel:
Send
+ Sync
+ 'static {
// Required method
fn lookup(&self, ip: IpAddr) -> IpInfo;
}Expand description
A geolocation / ASN source. Without one, IP changes are judged by network prefix only.
Lookups run on the request path and must be fast and non-blocking. With the maxmind
feature, MaxMindIntel reads GeoLite2 / GeoIP2 databases held in memory.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl<T: IpIntel + ?Sized> IpIntel for Arc<T>
Lets the guard share a source the app keeps a handle to, for example to reload MaxMind
databases.
impl<T: IpIntel + ?Sized> IpIntel for Arc<T>
Lets the guard share a source the app keeps a handle to, for example to reload MaxMind
databases.