Skip to content
andygup edited this page Dec 17, 2012 · 7 revisions

There are two "map" options:

###EsriMap includes the following functions:

  • setBasemap (mapType:String):void
  • setCenter(location:Object, zoomLevel:int = 14, mapType:String = "streets"):void
  • centerAtMyLocation (zoomLevel:int = 16):void
  • addPoint (point:Object /* MapPoint or [lat,lon] */, symbol:Symbol = null):Graphic
  • addLatLon(lat:Number, lon:Number, symbol:Symbol = null):Graphic
  • addLatLons(points:Array):Array /* Array of */
  • addLine(points:Array, symbol:Symbol = null):Graphic
  • addPolygon(points:Array /* Array of */, symbol:Symbol = null):Graphic
  • addressToLocation(address:String /* Single line address */, zoomLevel:int = -1):void
  • locationToAddress(mapPoint:MapPoint /* center */, distance:Number = 30.0):void
  • clearAll():void
  • clearPolygons():void
  • clearPolylines():void
  • clearPoints():void
  • route(source:Array = null, zoomFactor:Number = 2.0, responder:IResponder = null):void
  • showInfoWindow(lat:Number, lon:Number, content:UIComponent, label:String = null):void
  • hideInfoWindow():void
  • driveTimePolygon(times:Array, center:MapPoint = null):void // TODO

###EsriMobileMap adds 1 useful function:

  • whereAmI(zoomLevel:int = 16):void -- (Deprecated in the public API at v2. Replaced with centerAtMyLocation())

###Notes

  • At v2 centerAtMyLocation() works with both smartphone/tablet mobile deployments using GPS and WiFi, as well as HTML5 Geolocation in the browser.

Clone this wiki locally