Extends
Methods
-
Clear all painted overlays on the map related to this control
-
Closes address UI address element
-
Set current address to routing destination. If there is navbar enabled destination route is assigned with current opened address
-
Returns
cercalia
Map objectReturns:
Cercalia map.
-
Get class name.
Returns:
Class name.
-
Return geoentity data
module:cercaliagl/servers~GeEntity
from current address. Returnsnull
if this control isn't showing anyReturns:
ge GeEntity.
-
getDirection(lonLat, callbackFn, hideMarker, hidePopUp, preserveOriginalPosition)
-
Get direction giving position and shows response in UI address component. Optionally, you can provide addition callback function.
Name Type Description lonLat
module:cercaliagl/LonLat~LonLat Position
callbackFn
function Callback function
hideMarker
boolean Disables the default option to create a marker on the position
hidePopUp
boolean Disables the default option to show a popup with the position information
preserveOriginalPosition
boolean If true, the original position is preserved, false by default
-
Get control HTML Element
Returns:
HTML Element
-
Get control id.
Returns:
Id.
-
Returns
mapboxgl
Map object -
Get control name. Null if control has not defined name.
Returns:
Class name.
-
Center map to coordinates and draw a marker with a label with position coordinates. It doesn't obtain reverse geocoding data.
Name Type Description lonLat
module:cercaliagl/LonLat~LonLat Position.
panTo
boolean Pan Zoom to position.
-
Open a direction using GeEntity from server response. Then it shows addres UI with filled data about address components
Name Type Description ge
module:cercaliagl/servers~GeEntity GeEntity.
panTo
boolean (defaults to true) Pan Zoom to position.
ge.article
string | null | undefined ge.city
module:cercaliagl/servers~ObjectJSON | null | undefined ge.coord
module:cercaliagl/servers~Coord | null | undefined ge.country
module:cercaliagl/servers~ObjectJSON | null | undefined ge.dist
string | null | undefined ge.frc
string | null | undefined ge.housenumber
module:cercaliagl/servers~ObjectJSON | null | undefined ge.id
string | null | undefined ge.intersection
module:cercaliagl/servers~ObjectJSON | null | undefined ge.km
module:cercaliagl/servers~ObjectJSON | null | undefined ge.kmh
string | null | undefined ge.label
string | null | undefined ge.geometry
module:cercaliagl/servers~GeEntityGeometry | null | undefined ge.municipality
module:cercaliagl/servers~ObjectJSON | null | undefined ge.name
module:cercaliagl/servers~ObjectJSON | string | undefined ge.pos
string | null | undefined ge.postalcode
module:cercaliagl/servers~ObjectJSON | module:cercaliagl/servers~PostalCode | null | undefined ge.prefix
string | null | undefined ge.region
module:cercaliagl/servers~ObjectJSON | null | undefined ge.sname
string | null | undefined ge.subcategory_id
module:cercaliagl/servers~ObjectJSON | string | null | undefined ge.subregion
module:cercaliagl/servers~ObjectJSON | null | undefined ge.type
string | null | undefined ge.zonename
string | null | undefined ge.zonetype
string | null | undefined ge.zonetype
string | null | undefined ge.zonetype
string | null | undefined ge.zonetype
string | null | undefined -
Make a geocoding request to obtain postal code by country. It shows a marker and draw a polygon with its extension. Once postal code data is returned this function pan to postal code centroid. Optionally is possible to disable this pan.
Name Type Description countryId
string Country Id. For example:
ESP
orFRA
.pcode
string Postal code.
panTo
boolean (defaults to true) Optional pan to location.
-
Hide control.
-
Add a custom callback function called when a address is searched via context menu map. This function will receive
LonLat
andProximityResult
Name Type Description callbackFn
function | null Callback function
-
Show control.