Class: PlaceMap

Simplicite.UI.PlaceMap

new PlaceMap

PlaceMap controller

Parameters:
Name Type Description
app Simplicite.Ajax Ajax service
engine Simplicite.UI.Engine Main contoller
options { lat, lng, zoom, stroke, fill }
Source:
  • placemap.js, line 16

Methods

addCircle

Add a circle on map

Parameters:
Name Type Description
params { lat, lng, radius, color }
Source:
  • placemap.js, line 227

addMarker

Add a marker on map

Parameters:
Name Type Description
params { id, lat, lng, zoom, info, center }
Source:
  • placemap.js, line 124

addPolyline

Add a polygon on map

Parameters:
Name Type Description
params { list:[{ lat, lng }], color }
Source:
  • placemap.js, line 206

addRectangle

Add a rectangle on map

Parameters:
Name Type Description
params { lat1, lng1, lat2, lng2, color }
Source:
  • placemap.js, line 176

clearMap

Clear all markers and shapes

Source:
  • placemap.js, line 257

display

Display a map with a marker

Source:
  • placemap.js, line 266

initGeocoder

Init the Geocoder

Source:
  • placemap.js, line 280

initMap

Init a map in the container

Source:
  • placemap.js, line 58

load

Load the Javascript API

Source:
  • placemap.js, line 41

localize

Localize an address

Parameters:
Name Type Description
address full textual address
cbk callback(location, formattedAddress)
notify optional message handler
Source:
  • placemap.js, line 297

localizeAndDisplay

Localize an address and display the map on marker

Parameters:
Name Type Description
ctn container
address full textual address
cbk callback(location, formattedAddress)
notify optional message handler
Source:
  • placemap.js, line 328

removeMarkers

Remove all markers

Source:
  • placemap.js, line 166

removeShapes

Remove all shapes

Source:
  • placemap.js, line 248

staticMap

Return a static map as img

Parameters:
Name Type Description
p options { lat, lng, width, height, zoom, key }
cbk optional onload callback
Source:
  • placemap.js, line 87