GeocodingResult
in package
FinalYes
A point and where it came from. The source serves tests and the harness. When no point was produced, Api `GeocodingManager::resolveForAddress()` returns {@see GeocodingMiss} instead (the reason goes to the log).
Table of Contents
Constants
- SOURCE_CACHE : string = 'cache'
- `cms_system_geocoding_cache`: an earlier Google answer.
- SOURCE_DATASET : string = 'dataset'
- Free text found in the dataset (exact municipality or postcode match): filter and save without a selected municipality.
- SOURCE_EXTERNAL : string = 'external'
- External geocoder (Google).
- SOURCE_REGION : string = 'region'
- Center of the selected region (municipality without a street on save; `_r` in the filter).
- SOURCE_REGION_FALLBACK : string = 'region_fallback'
- Save: the external geocoder found nothing, so the center of the selected municipality is used.
Properties
- $coordinates : GeoCoordinates
- $regionId : int|null
- $source : string
Methods
- __construct() : mixed
Constants
SOURCE_CACHE
`cms_system_geocoding_cache`: an earlier Google answer.
public
string
SOURCE_CACHE
= 'cache'
SOURCE_DATASET
Free text found in the dataset (exact municipality or postcode match): filter and save without a selected municipality.
public
string
SOURCE_DATASET
= 'dataset'
SOURCE_EXTERNAL
External geocoder (Google).
public
string
SOURCE_EXTERNAL
= 'external'
SOURCE_REGION
Center of the selected region (municipality without a street on save; `_r` in the filter).
public
string
SOURCE_REGION
= 'region'
SOURCE_REGION_FALLBACK
Save: the external geocoder found nothing, so the center of the selected municipality is used.
public
string
SOURCE_REGION_FALLBACK
= 'region_fallback'
Properties
$coordinates read-only
public
GeoCoordinates
$coordinates
$regionId read-only
public
int|null
$regionId
= null
$source read-only
public
string
$source
Methods
__construct()
public
__construct(GeoCoordinates $coordinates, string $source[, int|null $regionId = null ]) : mixed
Parameters
- $coordinates : GeoCoordinates
- $source : string
- $regionId : int|null = null