MapBase.setZoomLevel Method

Sets the zoom level of the map.
 

Parameters

zoomLevel

Type: Number
A zoom level value of 0.1 or higher.
roundUp

Type: Boolean
A value indicating whether to round up the zoom level to the nearest tile zoom level rather than round down when using tile-based mapping. The default value is false.
Optional: True
 

Remarks

This method ensures the zoom level is correct given other map settings and redraws the map. It is preferred over changing viewportData values directly.