pub struct Country<'a> { /* private fields */ }
Expand description
Information on a country.
Returned by the Locations::country
function.
Implementations§
source§impl<'a> Country<'a>
impl<'a> Country<'a>
sourcepub fn code(&self) -> &'a str
pub fn code(&self) -> &'a str
The ISO 3166-1 alpha-2 code of the country.
It consists of two uppercase latin letters.
sourcepub fn continent_code(&self) -> &'a str
pub fn continent_code(&self) -> &'a str
The ISO 3166 code of the continent the country resides in.
"AF"
for Africa."AN"
for Antarctica."AS"
for Asia."EU"
for Europe."NA"
for North America."OC"
for Oceania."SA"
for South America.
Trait Implementations§
Auto Trait Implementations§
impl<'a> RefUnwindSafe for Country<'a>
impl<'a> Send for Country<'a>
impl<'a> Sync for Country<'a>
impl<'a> Unpin for Country<'a>
impl<'a> UnwindSafe for Country<'a>
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