Classes
Type Definitions
-
Options{Object}
-
Properties:
Name Type Description keystring Google Map Tiles API key. Get yours at https://developers.google.com/maps/documentation/tile/get-api-key.
mapTypestring
(defaults to 'roadmap')The type of base map.
languagestring
(defaults to 'en-US')An IETF language tag for information displayed on the tiles.
regionstring
(defaults to 'US')A Common Locale Data Repository (CLDR) region identifier that represents the user location.
imageFormatstring | undefined The image format used for the map tiles (e.g.
'jpeg', or'png').scalestring | undefined Scale for map elements (
'scaleFactor1x','scaleFactor2x', or'scaleFactor4x').highDpiboolean
(defaults to false)Use high-resolution tiles.
layerTypesArray.<string> | undefined The layer types added to the map (e.g.
'layerRoadmap','layerStreetview', or'layerTraffic').overlayboolean
(defaults to false)Display only the
layerTypesand not the underlyingmapType(only works iflayerTypesis provided).stylesArray.<Object> | undefined Custom styles applied to the map.
attributionsCollapsibleboolean
(defaults to true)Allow the attributions to be collapsed.
interpolateboolean
(defaults to true)Use interpolated values when resampling. By default, linear interpolation is used when resampling. Set to false to use the nearest neighbor instead.
cacheSizenumber | undefined Initial tile cache size. Will auto-grow to hold at least the number of tiles in the viewport.
reprojectionErrorThresholdnumber
(defaults to 0.5)Maximum allowed reprojection error (in pixels). Higher values can increase reprojection performance, but decrease precision.
tileLoadFunctionLoadFunction | undefined Optional function to load a tile given a URL. The default is
function(imageTile, src) { imageTile.getImage().src = src; };apiOptionsArray.<string> | undefined An array of values specifying additional options to apply.
wrapXboolean
(defaults to true)Wrap the world horizontally.
transitionnumber | undefined Duration of the opacity transition for rendering. To disable the opacity transition, pass
transition: 0.zDirectionnumber | NearestDirectionFunction
(defaults to 0)Choose whether to use tiles with a higher or lower zoom level when between integer zoom levels. See
getZForResolution. -
SessionTokenRequest{Object}
-
Properties:
Name Type Description mapTypestring The map type.
languagestring The language.
regionstring The region.
imageFormatstring | undefined The image format.
scalestring | undefined The scale.
highDpiboolean | undefined Use high resolution tiles.
layerTypesArray.<string> | undefined The layer types.
overlayboolean | undefined The overlay.
stylesArray.<Object> | undefined The styles.
apiOptionsArray.<string> | undefined An array of values specifying additional options to apply.
-
SessionTokenResponse{Object}
-
Properties:
Name Type Description sessionstring The session token.
expirystring The session token expiry (seconds since the epoch as a string).
tileWidthnumber The tile width.
tileHeightnumber The tile height.
imageFormatstring The image format.