[−][src]Struct ipdata::IpData
Methods
impl IpData
[src]
pub fn ip(&self) -> Result<IpAddr, AddrParseError>
[src]
Returns the IP address that was looked up.
pub fn is_eu(&self) -> bool
[src]
Returns true or false depending on whether the country is a recognized member of the European Union. The list of all EU countries is compiled from the European Union website: https://europa.eu/european-union/about-eu/countries_en.
pub fn city(&self) -> &String
[src]
Returns the name of the city where the IP Address is located.
pub fn region(&self) -> &String
[src]
Returns the name of the region where the IP address is located.
pub fn region_code(&self) -> &String
[src]
Returns the ISO 3166-2 region code for the IP address.
pub fn country_name(&self) -> &String
[src]
Returns the country name where the IP address is located.
pub fn country_code(&self) -> &String
[src]
Returns the 2 letter ISO 3166-1 alpha-2 code for the country where the IP address is located.
pub fn continent_name(&self) -> &String
[src]
Returns the name of the continent where the IP Address is located. One of Africa, Antarctica, Asia, Europe, North America, Oceania, South America.
pub fn latitude(&self) -> f64
[src]
Returns an approximate latitudinal location for the IP Address. Often near the center of population.
pub fn longitude(&self) -> f64
[src]
Returns an approximate longitudinal location for the IP Address. Often near the center of population.
pub fn asn(&self) -> &String
[src]
Returns the Autonomous System Number that references the IP Address's owning organization.
pub fn organization(&self) -> &String
[src]
Returns the name of the Organisation that owns the IP Address. This will default to the ISP name if the organisation is not available.
pub fn postal(&self) -> &String
[src]
Returns the postal code where the IP address is located.
pub fn calling_code(&self) -> &String
[src]
Returns the international calling code where the IP adress is located.
pub fn flag(&self) -> &String
[src]
Returns a URL to a PNG image with the flag of the country where the IP address is located.
pub fn emoji_flag(&self) -> &String
[src]
Returns an emoji version of the flag of the country where the IP address is located.
pub fn emoji_unicode(&self) -> &String
[src]
Returns the country flag emoji in unicode.
pub fn languages(&self) -> &Vec<Language>
[src]
Returns the location's languages.
pub fn currency(&self) -> &Currency
[src]
Returns the location's local currency.
pub fn time_zone(&self) -> &TimeZone
[src]
Returns the locations local time zone.
pub fn threat(&self) -> &Threat
[src]
Returns known threat data about the IP.
pub fn count(&self) -> u64
[src]
The total number of requests made by your API key in the last 24 hrs. Updates once a minute.
pub fn carrier(&self) -> &Option<Carrier>
[src]
Returns details of the IP Addresses's mobile carrier, if available.
Trait Implementations
impl Debug for IpData
[src]
impl<'de> Deserialize<'de> for IpData
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)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> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,