pub trait MapBoxGeocoderExt: Send + Sync {
// Required methods
fn permanent_geocode<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
query: &'life1 str,
limit: Option<u32>,
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = EveryMapResult<MapBoxSearchResponse>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn batch_geocode<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
queries: &'life1 [String],
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = EveryMapResult<Vec<MapBoxSearchResponse>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
}Expand description
Extension trait for MapBox-specific geocoder capabilities.
These methods are not part of the core Geocoder trait because they
are MapBox-specific. Import this trait to access them:
ⓘ
use everymap_providers_mapbox::MapBoxGeocoderExt;
let results = geocoder.permanent_geocode(query, &options).await?;Required Methods§
Sourcefn permanent_geocode<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
query: &'life1 str,
limit: Option<u32>,
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = EveryMapResult<MapBoxSearchResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn permanent_geocode<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
query: &'life1 str,
limit: Option<u32>,
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = EveryMapResult<MapBoxSearchResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Use the MapBox permanent geocoding endpoint (batch lookups).
Sourcefn batch_geocode<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
queries: &'life1 [String],
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = EveryMapResult<Vec<MapBoxSearchResponse>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn batch_geocode<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
queries: &'life1 [String],
language: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = EveryMapResult<Vec<MapBoxSearchResponse>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Batch geocode up to 50 forward/reverse queries.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".