@ionic-native/google-maps
- Version 5.5.0
- Published
- 817 kB
- No dependencies
- MIT license
Install
npm i @ionic-native/google-maps
yarn add @ionic-native/google-maps
pnpm add @ionic-native/google-maps
Overview
Ionic Native - Native plugins for ionic apps
Index
Variables
Classes
GoogleMap
- addCircle()
- addCircleSync()
- addGroundOverlay()
- addGroundOverlaySync()
- addKmlOverlay()
- addMarker()
- addMarkerCluster()
- addMarkerClusterSync()
- addMarkerSync()
- addPolygon()
- addPolygonSync()
- addPolyline()
- addPolylineSync()
- addTileOverlay()
- addTileOverlaySync()
- animateCamera()
- animateCameraZoomIn()
- animateCameraZoomOut()
- clear()
- fromLatLngToPoint()
- fromPointToLatLng()
- getCameraBearing()
- getCameraPosition()
- getCameraTarget()
- getCameraTilt()
- getCameraZoom()
- getDiv()
- getFocusedBuilding()
- getMyLocation()
- getVisibleRegion()
- moveCamera()
- moveCameraZoomIn()
- moveCameraZoomOut()
- panBy()
- remove()
- setAllGesturesEnabled()
- setCameraBearing()
- setCameraTarget()
- setCameraTilt()
- setCameraZoom()
- setClickable()
- setCompassEnabled()
- setDiv()
- setIndoorEnabled()
- setMapTypeId()
- setMyLocationButtonEnabled()
- setMyLocationEnabled()
- setOptions()
- setPadding()
- setTrafficEnabled()
- setVisible()
- toDataURL()
Marker
- getId()
- getMap()
- getOpacity()
- getPosition()
- getRotation()
- getSnippet()
- getTitle()
- getZIndex()
- hideInfoWindow()
- isDraggable()
- isInfoWindowShown()
- isVisible()
- remove()
- setAnimation()
- setDisableAutoPan()
- setDraggable()
- setFlat()
- setIcon()
- setIconAnchor()
- setInfoWindowAnchor()
- setOpacity()
- setPosition()
- setRotation()
- setSnippet()
- setTitle()
- setVisible()
- setZIndex()
- showInfoWindow()
Interfaces
Type Aliases
Variables
variable GoogleMapsAnimation
const GoogleMapsAnimation: { BOUNCE: string; DROP: string };
variable GoogleMapsEvent
const GoogleMapsEvent: { MAP_READY: string; MAP_CLICK: string; MAP_LONG_CLICK: string; POI_CLICK: string; MY_LOCATION_CLICK: string; MY_LOCATION_BUTTON_CLICK: string; INDOOR_BUILDING_FOCUSED: string; INDOOR_LEVEL_ACTIVATED: string; CAMERA_MOVE_START: string; CAMERA_MOVE: string; CAMERA_MOVE_END: string; OVERLAY_CLICK: string; POLYGON_CLICK: string; POLYLINE_CLICK: string; CIRCLE_CLICK: string; GROUND_OVERLAY_CLICK: string; INFO_CLICK: string; INFO_LONG_CLICK: string; INFO_CLOSE: string; INFO_OPEN: string; MARKER_CLICK: string; MARKER_DRAG: string; MARKER_DRAG_START: string; MARKER_DRAG_END: string; MAP_DRAG: string; MAP_DRAG_START: string; MAP_DRAG_END: string; KML_CLICK: string; PANORAMA_READY: string; PANORAMA_CAMERA_CHANGE: string; PANORAMA_LOCATION_CHANGE: string; PANORAMA_CLICK: string;};
You can listen to these events where appropriate
variable GoogleMapsMapTypeId
const GoogleMapsMapTypeId: { NORMAL: string; ROADMAP: string; SATELLITE: string; HYBRID: string; TERRAIN: string; NONE: string;};
variable StreetViewSource
const StreetViewSource: { DEFAULT: string; OUTDOOR: string };
Classes
class BaseArrayClass
class BaseArrayClass<T> extends BaseClass {}
https://github.com/mapsplugin/cordova-plugin-googlemaps-doc/blob/master/v2.0.0/class/BaseArrayClass/README.md
constructor
constructor(initialData?: any);
method empty
empty: (noNotify?: boolean) => void;
Removes all elements from the array.
Parameter noNotify
? {boolean} [options] Set true to prevent remove_at events.
method filter
filter: (fn: (element: T, index: number) => boolean) => T[];
The filter() method creates a new array with all elements that pass the test implemented by the provided function.
Parameter fn
{T[]} returns a new filtered array
method filterAsync
filterAsync: ( fn: (element: T, callback: (result: boolean) => void) => void) => Promise<T[]>;
The filterAsync() method creates a new array with all elements that pass the test implemented by the provided function.
Parameter fn
Parameter callback
{Promise<T[]>} returns a new filtered array
method forEach
forEach: (fn: (element: T, index?: number) => void) => void;
Iterate over each element, calling the provided callback.
Parameter fn
method forEachAsync
forEachAsync: (fn: (element: T, callback: () => void) => void) => Promise<void>;
Iterate over each element, calling the provided callback.
Parameter fn
{Promise}
method getArray
getArray: () => T[];
Returns a reference to the underlying Array. {Object[]}
method getAt
getAt: (index: number) => any;
Returns the element at the specified index.
Parameter index
{Object}
method getLength
getLength: () => number;
Returns the number of the elements. {number}
method indexOf
indexOf: (element: T) => number;
The indexOf() method returns the first index at which a given element can be found in the array, or -1 if it is not present.
Parameter element
{number}
method insertAt
insertAt: (index: number, element: T, noNotify?: boolean) => void;
Inserts an element at the specified index.
Parameter index
Parameter element
Parameter noNotify
? {boolean} [options] Set true to prevent insert_at event. {Object}
method map
map: (fn: (element: T, index: number) => any) => any[];
Iterate over each element, then Returns a new value. Then you can get the results of each callback.
Parameter fn
{Object[]} returns a new array with the results
method mapAsync
mapAsync: ( fn: (element: T, callback: (newElement: any) => void) => void) => Promise<any[]>;
Iterate over each element, calling the provided callback. Then you can get the results of each callback.
Parameter fn
Parameter callback
{Promise} returns a new array with the results
method mapSeries
mapSeries: ( fn: (element: T, callback: (newElement: any) => void) => void) => Promise<any[]>;
Same as
mapAsync
, but keep the execution orderParameter fn
Parameter callback
{Promise} returns a new array with the results
method pop
pop: (noNotify?: boolean) => T;
Removes the last element of the array and returns that element.
Parameter noNotify
? {boolean} [options] Set true to prevent remove_at event. {Object}
method push
push: (element: T, noNotify?: boolean) => void;
Adds one element to the end of the array and returns the new length of the array.
Parameter element
Parameter noNotify
? {boolean} Set true to prevent insert_at events.
method removeAt
removeAt: (index: number, noNotify?: boolean) => T;
Removes an element from the specified index.
Parameter index
Parameter noNotify
? {boolean} [options] Set true to prevent remove_at event.
method reverse
reverse: () => void;
The reverse() method reverses an array in place.
method setAt
setAt: (index: number, element: T, noNotify?: boolean) => void;
Sets an element at the specified index.
Parameter index
Parameter element
Parameter noNotify
? {boolean} [options] Set true to prevent set_at event.
method sort
sort: () => void;
The sort() method sorts the elements of an array in place and returns the array.
class BaseClass
class BaseClass {}
https://github.com/mapsplugin/cordova-plugin-googlemaps-doc/blob/master/v2.0.0/class/BaseClass/README.md
constructor
constructor(objInstance?: any);
method addEventListener
addEventListener: (eventName: string) => Observable<any>;
Adds an event listener.
Parameter eventName
event name you want to observe. {Observable}
method addEventListenerOnce
addEventListenerOnce: (eventName: string) => Promise<any>;
Adds an event listener that works once.
Parameter eventName
event name you want to observe. {Promise}
method addListenerOnce
addListenerOnce: (eventName: string) => Promise<any>;
Parameter eventName
event name you want to observe. {Promise}
Deprecated
Adds an event listener that works once.
method bindTo
bindTo: ( key: string, target: any, targetKey?: string, noNotify?: boolean) => void;
Bind a key to another object
Parameter key
The property name you want to observe.
Parameter target
The target object you want to observe.
Parameter targetKey
? {string} [options] The property name you want to observe. If you omit this, the
key
argument is used.Parameter noNotify
? {boolean} [options] True if you want to prevent
(key)_changed
event when you bind first time, because the internal status is changed fromundefined
to something.
method destroy
destroy: () => void;
Executes off() and empty()
method empty
empty: () => void;
Clears all stored values
method get
get: (key: string) => any;
Gets a value
Parameter key
method hasEventListener
hasEventListener: () => boolean;
Return true if this object has event listener for event name
Parameter eventName
Event name {boolean}
method off
off: (eventName?: string, listener?: (...parameters: any[]) => void) => void;
Alias of
removeEventListener
Parameter eventName
[options] Event name
Parameter listener
[options] Event listener
method on
on: (eventName: string) => Observable<any>;
Alias of
addEventListener
Parameter key
The property name you want to observe. {Observable}
method one
one: (eventName: string) => Promise<any>;
Alias of
addEventListenerOnce
Parameter key
The property name you want to observe. {Promise}
method removeEventListener
removeEventListener: ( eventName?: string, listener?: (...parameters: any[]) => void) => void;
Remove event listener(s) The
removeEventListener()
has three usages: - removeEventListener("eventName", listenerFunction); This removes one particular event listener - removeEventListener("eventName"); This removes the event listeners that added for the event name. - removeEventListener(); This removes all listeners.Parameter eventName
[options] Event name
Parameter listener
[options] Event listener
method set
set: (key: string, value: any, noNotify?: boolean) => void;
Sets a value
Parameter key
The key name for the value.
(key)_changed
will be fired when you set value through this method.Parameter value
Parameter noNotify
[options] True if you want to prevent firing the
(key)_changed
event.
method trigger
trigger: (eventName: string, ...parameters: any[]) => void;
Dispatch event.
Parameter eventName
Event name
Parameter parameters
[options] The data you want to pass to event listerners.
class Circle
class Circle extends BaseClass {}
https://github.com/mapsplugin/cordova-plugin-googlemaps-doc/blob/master/v2.0.0/class/Circle/README.md
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getBounds
getBounds: () => LatLngBounds;
Returns the latLngBounds (rectangle) that contains the circle. {LatLngBounds}
method getCenter
getCenter: () => ILatLng;
Returns the current center position {ILatLng}
method getClickable
getClickable: () => boolean;
Returns true if the circle is clickable. {boolean}
method getFillColor
getFillColor: () => string;
Returns the current circle filling color (inner color). {string}
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method getRadius
getRadius: () => number;
Returns the current circle radius. {number}
method getStrokeColor
getStrokeColor: () => string;
Returns the current circle stroke color (outer color). {string}
method getStrokeWidth
getStrokeWidth: () => number;
Returns the current circle stroke width (unit: pixel). {number}
method getVisible
getVisible: () => boolean;
Returns true if the circle is visible. {boolean}
method getZIndex
getZIndex: () => number;
Returns the current circle zIndex. {number}
method remove
remove: () => void;
Remove the circle.
method setCenter
setCenter: (latLng: ILatLng) => void;
Changes the center position.
Parameter latLng
method setClickable
setClickable: (clickable: boolean) => void;
Changes click-ability of the circle.
Parameter clickable
method setFillColor
setFillColor: (color: string) => void;
Changes the filling color (inner color).
Parameter color
method setRadius
setRadius: (radius: number) => void;
Changes the circle radius.
Parameter radius
method setStrokeColor
setStrokeColor: (strokeColor: string) => void;
Changes the stroke color (outter color).
Parameter strokeColor
method setStrokeWidth
setStrokeWidth: (strokeWidth: number) => void;
Changes the stroke width.
Parameter strokeWidth
method setVisible
setVisible: (visible: boolean) => void;
Set circle visibility
Parameter visible
method setZIndex
setZIndex: (zIndex: number) => void;
Changes the circle zIndex order.
Parameter zIndex
class Encoding
class Encoding {}
method decodePath
static decodePath: (encoded: string, precision?: number) => ILatLng[];
Decodes an encoded path string into a sequence of LatLngs.
Parameter encoded
an encoded path string
Parameter precision
? {number} default: 5 {LatLng}
This method is static. Please use Encoding.decodePath()
method encodePath
static encodePath: (path: ILatLng[] | BaseArrayClass<ILatLng>) => string;
Encodes a sequence of LatLngs into an encoded path string.
Parameter path
a sequence of LatLngs {string}
This method is static. Please use Encoding.encodePath()
class Environment
class Environment {}
method getLicenseInfo
static getLicenseInfo: () => Promise<any>;
Get the open source software license information for Google Maps SDK for iOS. {Promise}
This method is static. Please use Environment.getLicenseInfo()
method setBackgroundColor
static setBackgroundColor: (color: string) => void;
Specifies the background color of the app.
Parameter color
This method is static. Please use Environment.setBackgroundColor()
method setEnv
static setEnv: (envOptions: EnvOptions) => void;
Set environment variables.
class Geocoder
class Geocoder {}
method geocode
static geocode: ( request: GeocoderRequest) => Promise<GeocoderResult[] | BaseArrayClass<GeocoderResult[]>>;
This method is static. Please use Geocoder.geocode()
Converts position to address and vice versa
Parameter request
Request object with either an address or a position {Promise<GeocoderResult[] | BaseArrayClass>}
class GoogleMap
class GoogleMap extends BaseClass {}
constructor
constructor( element: string | HTMLElement, options?: GoogleMapOptions, __timeout?: number);
method addCircle
addCircle: (options: CircleOptions) => Promise<Circle | any>;
Adds a circle
Parameter options
options {Promise}
method addCircleSync
addCircleSync: (options: CircleOptions) => Circle;
Adds a circle in synchronous
Parameter options
options {Circle}
method addGroundOverlay
addGroundOverlay: ( options: GroundOverlayOptions) => Promise<GroundOverlay | any>;
Adds a ground overlay
Parameter options
options {Promise}
method addGroundOverlaySync
addGroundOverlaySync: (options: GroundOverlayOptions) => GroundOverlay;
Adds a ground overlay in synchronous
Parameter options
options {GroundOverlay}
method addKmlOverlay
addKmlOverlay: (options: KmlOverlayOptions) => Promise<KmlOverlay>;
Adds a kml overlay
Parameter options
options {Promise}
method addMarker
addMarker: (options: MarkerOptions) => Promise<Marker | any>;
Adds a marker
Parameter options
options {Promise}
method addMarkerCluster
addMarkerCluster: ( options: MarkerClusterOptions) => Promise<MarkerCluster | any>;
Adds a marker cluster
Parameter options
options {Promise}
method addMarkerClusterSync
addMarkerClusterSync: (options: MarkerClusterOptions) => MarkerCluster;
Adds a marker cluster in synchronous
Parameter options
options
Returns
{MarkerCluster}
method addMarkerSync
addMarkerSync: (options: MarkerOptions) => Marker;
Adds a marker in synchronous
Parameter options
options
Returns
{Marker}
method addPolygon
addPolygon: (options: PolygonOptions) => Promise<Polygon | any>;
Adds a polygon
Parameter options
options {Promise}
method addPolygonSync
addPolygonSync: (options: PolygonOptions) => Polygon;
Adds a polygon in synchronous
Parameter options
options {Polygon}
method addPolyline
addPolyline: (options: PolylineOptions) => Promise<Polyline | any>;
Adds a polyline
Parameter options
options {Promise}
method addPolylineSync
addPolylineSync: (options: PolylineOptions) => Polyline;
Adds a polyline in synchronous
Parameter options
options {Polyline}
method addTileOverlay
addTileOverlay: (options: TileOverlayOptions) => Promise<TileOverlay | any>;
Adds a tile overlay
Parameter options
options {Promise}
method addTileOverlaySync
addTileOverlaySync: (options: TileOverlayOptions) => TileOverlay;
Adds a tile overlay in synchronous
Parameter options
options {TileOverlay}
method animateCamera
animateCamera: (cameraPosition: CameraPosition<any>) => Promise<any>;
Moves the camera with animation {Promise}
method animateCameraZoomIn
animateCameraZoomIn: () => Promise<any>;
Zooming in the camera with animation {Promise}
method animateCameraZoomOut
animateCameraZoomOut: () => Promise<any>;
Zooming out the camera with animation {Promise}
method clear
clear: () => Promise<any>;
Remove all overlays, such as marker {Promise}
method fromLatLngToPoint
fromLatLngToPoint: (latLng: ILatLng) => Promise<any[]>;
Convert the unit from LatLng to the pixels from the left/top of the map div {Promise}
method fromPointToLatLng
fromPointToLatLng: (point: number[]) => Promise<LatLng>;
Convert the unit from the pixels from the left/top to the LatLng {Promise}
method getCameraBearing
getCameraBearing: () => number;
Get the current camera bearing {number}
method getCameraPosition
getCameraPosition: () => CameraPosition<ILatLng>;
Get the position of the camera. {CameraPosition}
method getCameraTarget
getCameraTarget: () => ILatLng;
Get the current camera target position {ILatLng}
method getCameraTilt
getCameraTilt: () => number;
Get the current camera tilt (view angle) {number}
method getCameraZoom
getCameraZoom: () => number;
Get the current camera zoom level {number}
method getDiv
getDiv: () => HTMLElement;
Returns the map HTML element {HTMLElement}
method getFocusedBuilding
getFocusedBuilding: () => Promise<any>;
Get the currently focused building {Promise}
method getMyLocation
getMyLocation: (options?: MyLocationOptions) => Promise<MyLocation>;
Get the current device location {Promise}
method getVisibleRegion
getVisibleRegion: () => VisibleRegion;
Get the current visible region (southWest and northEast) {VisibleRegion}
method moveCamera
moveCamera: (cameraPosition: CameraPosition<any>) => Promise<any>;
Moves the camera without animation {Promise}
method moveCameraZoomIn
moveCameraZoomIn: () => Promise<any>;
Zooming in the camera without animation {Promise}
method moveCameraZoomOut
moveCameraZoomOut: () => Promise<any>;
Zooming out the camera without animation {Promise}
method panBy
panBy: (x: number, y: number) => void;
Changes the center of the map by the given distance in pixels
Parameter x
Parameter y
method remove
remove: () => Promise<any>;
Destroy a map completely {Promise}
method setAllGesturesEnabled
setAllGesturesEnabled: (enabled: boolean) => void;
Sets the preference for whether all gestures should be enabled or disabled
Parameter enabled
method setCameraBearing
setCameraBearing: (bearing: any) => void;
Set camera bearing
Parameter bearing
method setCameraTarget
setCameraTarget: (latLng: ILatLng | ILatLng[]) => void;
Set the center position of the camera view
Parameter latLng
method setCameraTilt
setCameraTilt: (tiltAngle: number) => void;
Set the camera view angle
Parameter tiltAngle
Tilt angle
method setCameraZoom
setCameraZoom: (zoomLevel: number) => void;
Set zoom level of the camera
Parameter zoomLevel
Zoom level
method setClickable
setClickable: (isClickable: boolean) => void;
Set false to ignore all clicks on the map
Parameter isClickable
method setCompassEnabled
setCompassEnabled: (enabled: boolean) => void;
Set true if you want to show the compass button
Parameter enabled
method setDiv
setDiv: (domNode?: HTMLElement | string) => void;
Changes the map div
Parameter domNode
[options] If you want to display the map in an html element, you need to specify an element or id. If omit this argument, the map is detached from webview.
method setIndoorEnabled
setIndoorEnabled: (enabled: boolean) => void;
Set true if you want to show the indoor map
Parameter enabled
method setMapTypeId
setMapTypeId: (mapTypeId: MapType | string) => void;
Changes the map type id
Parameter mapTypeId
method setMyLocationButtonEnabled
setMyLocationButtonEnabled: (enabled: boolean) => void;
Set true if you want to show the MyLocation button
Parameter enabled
method setMyLocationEnabled
setMyLocationEnabled: (enabled: boolean) => void;
Set true if you want to show the MyLocation control (blue dot)
Parameter enabled
method setOptions
setOptions: (options: GoogleMapOptions) => void;
Set options
Parameter options
method setPadding
setPadding: ( top: number, right?: number, bottom?: number, left?: number) => void;
Adjust the map padding (same as CSS padding rule)
Parameter top
Parameter right
Parameter left
Parameter bottom
method setTrafficEnabled
setTrafficEnabled: (enabled: boolean) => void;
Set true if you want to show the traffic layer
Parameter enabled
method setVisible
setVisible: (visible: boolean) => void;
Set visibility of the map
Parameter visible
method toDataURL
toDataURL: (options?: ToDataUrlOptions) => Promise<string>;
Returns the base64 encoded screen capture of the map.
Parameter options
[options] options {Promise}
class GoogleMaps
class GoogleMaps extends IonicNativePlugin {}
Google Maps This plugin uses the native Google Maps SDK Note: As of Ionic native 4.0, this using the 2.0 version of the google maps plugin. Please make sure your plugin is updated
import {GoogleMaps,GoogleMap,GoogleMapsEvent,GoogleMapOptions,CameraPosition,MarkerOptions,Marker} from '@ionic-native/google-maps';import { Component } from "@angular/core/";@Component({selector: 'page-home',templateUrl: 'home.html'})export class HomePage {map: GoogleMap;constructor() { }ionViewDidLoad() {this.loadMap();}loadMap() {let mapOptions: GoogleMapOptions = {camera: {target: {lat: 43.0741904,lng: -89.3809802},zoom: 18,tilt: 30}}this.map = GoogleMaps.create('map_canvas', mapOptions);let marker: Marker = this.map.addMarkerSync({title: 'Ionic',icon: 'blue',animation: 'DROP',position: {lat: 43.0741904,lng: -89.3809802}});marker.on(GoogleMapsEvent.MARKER_CLICK).subscribe(() => {alert('clicked');});});}}GoogleMaps GoogleMap StreetView Circle Encoding Environment Geocoder GroundOverlay HtmlInfoWindow Geocoder LatLng LatLngBounds Marker MarkerCluster Polygon Polyline Spherical KmlOverlay Poly TileOverlay BaseClass BaseArrayClass GoogleMapOptions CameraPosition CircleOptions GeocoderRequest GeocoderResult GroundOverlayOptions ILatLng MarkerIcon MarkerOptions MarkerClusterIcon MarkerClusterOptions MyLocation MyLocationOptions PolygonOptions PolylineOptions TileOverlayOptions KmlOverlayOptions VisibleRegion
method create
static create: ( element: string | HTMLElement | GoogleMapOptions, options?: GoogleMapOptions) => GoogleMap;
Creates a new GoogleMap instance
Parameter element
Element ID or reference to attach the map to
Parameter options
[options] Options {GoogleMap}
keep this for backward compatibility.
method createPanorama
static createPanorama: ( element: string | HTMLElement, options?: StreetViewOptions) => StreetViewPanorama;
Creates a new StreetView instance
Parameter element
Element ID or reference to attach the map to
Parameter options
[options] Options {StreetViewPanorama}
class GroundOverlay
class GroundOverlay extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getBearing
getBearing: () => number;
Returns the current bearing value
method getClickable
getClickable: () => boolean;
Returns true if the ground overlay is clickable {boolean}
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method getOpacity
getOpacity: () => number;
Returns the current opacity {number}
method getVisible
getVisible: () => boolean;
Returns true if the ground overlay is visible {boolean}
method getZIndex
getZIndex: () => number;
Returns the current ground overlay zIndex {number}
method remove
remove: () => void;
Remove the ground overlay
method setBearing
setBearing: (bearing: number) => void;
Changes the bearing of the ground overlay
Parameter bearing
method setBounds
setBounds: (bounds: ILatLng[]) => void;
Changes the bounds of the GroundOverlay
Parameter bounds
method setClickable
setClickable: (clickable: boolean) => void;
Changes click-ability of the ground overlay
Parameter clickable
method setImage
setImage: (imageUrl: string) => void;
Changes the image of the ground overlay
Parameter imageUrl
URL of image
method setOpacity
setOpacity: (opacity: number) => void;
Changes the opacity of the ground overlay from 0.0 to 1.0
Parameter opacity
method setVisible
setVisible: (visible: boolean) => void;
Changes visibility of the ground overlay
Parameter visible
method setZIndex
setZIndex: (index: number) => void;
Changes the ground overlay zIndex order
Parameter index
class HtmlInfoWindow
class HtmlInfoWindow extends BaseClass {}
constructor
constructor();
method close
close: () => void;
Close the htmlInfoWindow
method open
open: (marker: any) => any;
Open the htmlInfoWindow
Parameter marker
method setBackgroundColor
setBackgroundColor: (color: string) => void;
Changes the backgroundColor
Parameter color
method setContent
setContent: (content: string | Element, cssOptions?: any) => void;
Set your HTML contents.
Parameter content
String containing text or HTML element
Parameter cssOptions
? {any} CSS styles for the container element of HTMLInfoWindow
class KmlOverlay
class KmlOverlay extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getClickable
getClickable: () => boolean;
Returns true if the KmlOverlay is clickable {boolean}
method getDefaultViewport
getDefaultViewport: () => CameraPosition<ILatLng | ILatLng[]>;
Returns the viewport to contains all overlays
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => GoogleMap;
Returns the map instance. {GoogleMap}
method getVisible
getVisible: () => boolean;
Returns true if the kml overlay is visible {boolean}
method remove
remove: () => void;
Remove the KmlOverlay
method setClickable
setClickable: (clickable: boolean) => void;
Changes click-ability of the KmlOverlay
Parameter clickable
method setVisible
setVisible: (visible: boolean) => void;
Changes visibility of the kml overlay
Parameter visible
class LatLng
class LatLng implements ILatLng {}
constructor
constructor(lat: number, lng: number);
property lat
lat: number;
property lng
lng: number;
method equals
equals: (other: ILatLng) => boolean;
method toString
toString: () => string;
method toUrlValue
toUrlValue: (precision?: number) => string;
class LatLngBounds
class LatLngBounds implements ILatLngBounds {}
constructor
constructor(points?: ILatLng[]);
property northeast
northeast: ILatLng;
property southwest
southwest: ILatLng;
property type
type: string;
method contains
contains: (LatLng: ILatLng) => boolean;
Returns true if the given lat/lng is in this bounds.
Parameter LatLng
method extend
extend: (LatLng: ILatLng) => void;
Extends this bounds to contain the given point.
Parameter LatLng
method getCenter
getCenter: () => LatLng;
Computes the center of this LatLngBounds {LatLng}
method toString
toString: () => string;
Converts to string {string}
method toUrlValue
toUrlValue: (precision?: number) => string;
Returns a string of the form "lat_sw,lng_sw,lat_ne,lng_ne" for this bounds, where "sw" corresponds to the southwest corner of the bounding box, while "ne" corresponds to the northeast corner of that box.
Parameter precision
{string}
class LocationService
class LocationService {}
method getMyLocation
static getMyLocation: (options?: MyLocationOptions) => Promise<MyLocation>;
Get the current device location without map {Promise}
method hasPermission
static hasPermission: () => Promise<boolean>;
Return true if the application has geolocation permission {Promise}
class Marker
class Marker extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method getOpacity
getOpacity: () => number;
Returns the marker opacity. {number} Opacity
method getPosition
getPosition: () => ILatLng;
Returns the marker position. {ILatLng}
method getRotation
getRotation: () => number;
Returns the marker rotation angle. {number}
method getSnippet
getSnippet: () => string;
Returns the snippet strings. {string}
method getTitle
getTitle: () => string;
Returns the title strings. {string}
method getZIndex
getZIndex: () => number;
Get z-index {number}
method hideInfoWindow
hideInfoWindow: () => void;
Hide the normal infoWindow of the marker.
method isDraggable
isDraggable: () => boolean;
Returns true if the marker drag is enabled. {boolean}
method isInfoWindowShown
isInfoWindowShown: () => boolean;
Returns true if the infoWindow is shown on the marker {boolean}
method isVisible
isVisible: () => boolean;
Returns true if the marker is visible
method remove
remove: () => void;
Remove the marker.
method setAnimation
setAnimation: (animation: string) => void;
Specify the animation either
DROP
orBOUNCE
Parameter animation
method setDisableAutoPan
setDisableAutoPan: (disableAutoPan: boolean) => void;
Set true if you **do not want** to move the map when you click on the marker.
Parameter disableAutoPan
method setDraggable
setDraggable: (draggable: boolean) => void;
Set true if you allow all users to drag the marker.
Parameter draggable
method setFlat
setFlat: (flat: boolean) => void;
Set true if you want to be flat marker.
Parameter flat
method setIcon
setIcon: (icon: MarkerIcon) => void;
Changes icon url and/or size
Parameter icon
method setIconAnchor
setIconAnchor: (x: number, y: number) => void;
Changes the info window anchor. This defaults to 50% from the left of the image and at the bottom of the image.
Parameter x
Distance from left of the icon image in pixels.
Parameter y
Distance from top of the icon image in pixels.
method setInfoWindowAnchor
setInfoWindowAnchor: (x: number, y: number) => void;
Changes the info window anchor. This defaults to 50% from the left of the image and at the top of the image.
Parameter x
Distance from left of the icon image in pixels.
Parameter y
Distance from top of the icon image in pixels.
method setOpacity
setOpacity: (alpha: number) => void;
Changes the marker opacity from 0.0 to 1.0.
Parameter alpha
Opacity
method setPosition
setPosition: (latLng: ILatLng) => void;
Set the marker position.
Parameter latLng
method setRotation
setRotation: (rotation: number) => void;
Set the marker rotation angle.
Parameter rotation
method setSnippet
setSnippet: (snippet: string) => void;
Changes snippet of the normal infoWindow.
Parameter snippet
method setTitle
setTitle: (title: string) => void;
Changes title of the normal infoWindow.
Parameter title
method setVisible
setVisible: (visible: boolean) => void;
Set false if you want to hide the marker.
Parameter visible
method setZIndex
setZIndex: (zIndex: number) => void;
Higher zIndex value overlays will be drawn on top of lower zIndex value tile layers and overlays.
Parameter y
z-index
method showInfoWindow
showInfoWindow: () => void;
Show the normal infoWindow of the marker.
class MarkerCluster
class MarkerCluster extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method addMarker
addMarker: (marker: MarkerOptions) => void;
Add one marker location
Parameter marker
one location
Parameter skipRedraw
? {boolean} marker cluster does not redraw the marker cluster if true.
method addMarkers
addMarkers: (markers: MarkerOptions[]) => void;
Add marker locations
Parameter markers
multiple location
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method remove
remove: () => void;
Remove the marker cluster
class Poly
class Poly {}
method containsLocation
static containsLocation: (location: ILatLng, path: ILatLng[]) => boolean;
Returns true if the specified location is in the polygon path
Parameter location
Parameter path
{boolean}
method isLocationOnEdge
static isLocationOnEdge: (location: ILatLng, path: ILatLng[]) => boolean;
Returns true if the specified location is on the polyline path
Parameter location
Parameter path
{boolean}
class Polygon
class Polygon extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getClickable
getClickable: () => boolean;
Returns true if the polygon is clickable
method getFillColor
getFillColor: () => string;
Returns the current polygon filling color (inner color). {string}
method getGeodesic
getGeodesic: () => boolean;
Returns true if the polygon is geodesic. {boolean}
method getHoles
getHoles: () => BaseArrayClass<ILatLng[]>;
Returns an instance of the BaseArrayClass. You can modify the holes. {BaseArrayClass<ILatLng[]>}
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method getPoints
getPoints: () => BaseArrayClass<ILatLng>;
Returns an instance of the BaseArrayClass. You can modify the points. {BaseArrayClass}
method getStrokeColor
getStrokeColor: () => string;
Returns the current polygon stroke color (outer color) {string}
method getStrokeWidth
getStrokeWidth: () => number;
Returns the polygon stroke width
method getVisible
getVisible: () => boolean;
Returns true if the polygon is visible {boolean}
method getZIndex
getZIndex: () => number;
Returns the current polygon zIndex {number}
method remove
remove: () => void;
Remove the polygon.
method setClickable
setClickable: (clickable: boolean) => void;
Changes click-ability of the polygon
Parameter clickable
method setFillColor
setFillColor: (fillColor: string) => void;
Changes the filling color (inner color)
Parameter fillColor
method setGeodesic
setGeodesic: (geodesic: boolean) => void;
When true, edges of the polygon are interpreted as geodesic and will follow the curvature of the Earth.
Parameter geodesic
method setHoles
setHoles: (holes: ILatLng[][]) => void;
Changes the polygon holes.
Parameter holes
method setPoints
setPoints: (points: ILatLng[]) => void;
Changes the polygon points.
Parameter points
method setStrokeColor
setStrokeColor: (strokeColor: string) => void;
Changes the stroke color (outer color)
Parameter strokeColor
method setStrokeWidth
setStrokeWidth: (strokeWidth: number) => void;
Changes the polygon stroke width
method setVisible
setVisible: (visible: boolean) => void;
Changes visibility of the polygon
Parameter visible
method setZIndex
setZIndex: (zIndex: number) => void;
Changes the polygon zIndex order.
Parameter zIndex
class Polyline
class Polyline extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getClickable
getClickable: () => boolean;
Returns true if the polyline is clickable {boolean}
method getGeodesic
getGeodesic: () => boolean;
Returns true if the polyline is geodesic
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method getPoints
getPoints: () => BaseArrayClass<ILatLng>;
Returns an instance of the BaseArrayClass You can modify the points. {BaseArrayClass}
method getStrokeColor
getStrokeColor: () => string;
Returns the current polyline color {string}
method getStrokeWidth
getStrokeWidth: () => number;
Returns the current stroke width (unit: pixel). {number}
method getVisible
getVisible: () => boolean;
Returns true if the polyline is visible {boolean}
method getZIndex
getZIndex: () => number;
Returns the current polyline zIndex {number}
method remove
remove: () => void;
Remove the polyline
method setClickable
setClickable: (clickable: boolean) => void;
Changes click-ability of the polyline
Parameter clickable
method setGeoDesic
setGeoDesic: (geoDesic: boolean) => void;
When true, edges of the polyline are interpreted as geodesic and will follow the curvature of the Earth.
Parameter geoDesic
method setPoints
setPoints: (points: ILatLng[]) => void;
Changes the polyline points.
Parameter points
method setStrokeColor
setStrokeColor: (strokeColor: string) => void;
Changes the polyline color
Parameter strokeColor
method setStrokeWidth
setStrokeWidth: (strokeWidth: number) => void;
Changes the polyline stroke width
Parameter strokeWidth
method setVisible
setVisible: (visible: boolean) => void;
Changes visibility of the polyline
Parameter visible
method setZIndex
setZIndex: (index: number) => void;
Changes the polyline zIndex order.
Parameter index
class Spherical
class Spherical {}
method computeArea
static computeArea: (path: ILatLng[] | BaseArrayClass<ILatLng>) => number;
Returns the area of a closed path. The computed area uses the same units as the radius.
Parameter path
. {number}
This method is static. Please use Spherical.computeArea()
method computeDistanceBetween
static computeDistanceBetween: (from: ILatLng, to: ILatLng) => number;
Returns the distance, in meters, between two LatLngs.
Parameter locationA
Parameter locationB
{number}
This method is static. Please use Spherical.computeDistanceBetween()
method computeHeading
static computeHeading: (from: ILatLng, to: ILatLng) => number;
Returns the heading from one LatLng to another LatLng. Headings are expressed in degrees clockwise from North within the range (-180,180).
Parameter from
Parameter to
{number}
This method is static. Please use Spherical.computeHeading()
method computeLength
static computeLength: (path: ILatLng[] | BaseArrayClass<ILatLng>) => number;
Returns the length of the given path.
Parameter path
{number}
This method is static. Please use Spherical.computeLength()
method computeOffset
static computeOffset: ( from: ILatLng, distance: number, heading: number) => LatLng;
Returns the LatLng resulting from moving a distance from an origin in the specified heading (expressed in degrees clockwise from north)
Parameter from
Parameter distance
Parameter heading
{LatLng}
This method is static. Please use Spherical.computeOffset()
method computeOffsetOrigin
static computeOffsetOrigin: ( to: ILatLng, distance: number, heading: number) => LatLng;
Returns the location of origin when provided with a LatLng destination, meters travelled and original heading. Headings are expressed in degrees clockwise from North. This function returns null when no solution is available.
Parameter to
The destination LatLng.
Parameter distance
The distance travelled, in meters.
Parameter heading
The heading in degrees clockwise from north. {LatLng}
This method is static. Please use Spherical.computeOffsetOrigin()
method computeSignedArea
static computeSignedArea: (path: ILatLng[] | BaseArrayClass<ILatLng>) => number;
Returns the signed area of a closed path. The signed area may be used to determine the orientation of the path.
Parameter path
. {number}
This method is static. Please use Spherical.computeSignedArea()
method interpolate
static interpolate: (from: ILatLng, to: ILatLng, fraction: number) => LatLng;
Returns the LatLng which lies the given fraction of the way between the origin LatLng and the destination LatLng.
Parameter from
The LatLng from which to start.
Parameter to
The LatLng toward which to travel.
Parameter fraction
A fraction of the distance to travel from 0.0 to 1.0 . {LatLng}
This method is static. Please use Spherical.interpolate()
class StreetViewPanorama
class StreetViewPanorama extends BaseClass {}
constructor
constructor(element: string | HTMLElement, options?: StreetViewOptions);
method getLinks
getLinks: () => StreetViewNavigationLink[];
Return the navigation links (StreetViewLocation.links) {StreetViewNavigationLink[]}
method getLocation
getLocation: () => StreetViewLocation;
Return the current location {StreetViewLocation}
method getNavigationEnabled
getNavigationEnabled: () => boolean;
Return true if the navigation control is enabled. {boolean}
method getPanningGesturesEnabled
getPanningGesturesEnabled: () => boolean;
Return true if the panning gesture is enabled. {boolean}
method getPanoId
getPanoId: () => string;
Return the current panorama id {string}
method getPosition
getPosition: () => ILatLng;
Return the current position (StreetViewLocation.latLng) {string}
method getStreetNamesEnabled
getStreetNamesEnabled: () => boolean;
Return true if the street names control is enabled. {boolean}
method getZoomGesturesEnabled
getZoomGesturesEnabled: () => boolean;
Return true if the zooming gesture is enabled. {boolean}
method remove
remove: () => Promise<any>;
Destroy a panorama completely {Promise}
method setNavigationEnabled
setNavigationEnabled: (gestureEnable: boolean) => void;
Toggles the ability for users to move between panoramas.
Parameter gestureEnable
method setPanningGesturesEnabled
setPanningGesturesEnabled: (gestureEnable: boolean) => void;
Toggles the ability for users to use pan around on the panorama using gestures.
Parameter gestureEnable
method setPosition
setPosition: (cameraPosition: String | StreetViewSetPositionOption) => void;
Sets the StreetViewPanorama to a given location.
method setPov
setPov: (pov: StreetViewCameraPano) => void;
Sets the point of view for the Street View panorama.
method setStreetNamesEnabled
setStreetNamesEnabled: (gestureEnable: boolean) => void;
Toggles the ability for users to see street names on the panorama.
Parameter gestureEnable
method setZoomGesturesEnabled
setZoomGesturesEnabled: (gestureEnable: boolean) => void;
Toggles the ability for users to zoom on the panorama using gestures.
Parameter gestureEnable
class TileOverlay
class TileOverlay extends BaseClass {}
constructor
constructor(_map: GoogleMap, _objectInstance: any);
method getFadeIn
getFadeIn: () => boolean;
Get whether the tiles should fade in {boolean}
method getId
getId: () => string;
Returns the ID of instance. {string}
method getMap
getMap: () => any;
Returns the map instance. {GoogleMap}
method getOpacity
getOpacity: () => number;
Returns the opacity of the tile overlay {number}
method getTileSize
getTileSize: () => any;
Get tile size
method getVisible
getVisible: () => boolean;
Returns true if the tile overlay is visible {boolean}
method getZIndex
getZIndex: () => number;
Returns the zIndex of the tile overlay {number}
method remove
remove: () => void;
Remove the tile overlay
method setFadeIn
setFadeIn: (fadeIn: boolean) => void;
Set whether the tiles should fade in.
Parameter fadeIn
method setOpacity
setOpacity: (opacity: number) => void;
Set the opacity of the tile overlay
Parameter opacity
method setVisible
setVisible: (visible: boolean) => void;
Set false if you want to hide
Parameter visible
method setZIndex
setZIndex: (zIndex: number) => void;
Set the zIndex of the tile overlay
Parameter zIndex
class VisibleRegion
class VisibleRegion implements ILatLngBounds {}
constructor
constructor( southwest: LatLngBounds, northeast: LatLngBounds, farLeft: ILatLng, farRight: ILatLng, nearLeft: ILatLng, nearRight: ILatLng);
property farLeft
farLeft: ILatLng;
The farLeft indicates the lat/lng of the top-left of the map view.
property farRight
farRight: ILatLng;
The farRight indicates the lat/lng of the top-right of the map view.
property nearLeft
nearLeft: ILatLng;
The nearLeft indicates the lat/lng of the bottom-left of the map view.
property nearRight
nearRight: ILatLng;
The nearRight indicates the lat/lng of the bottom-right of the map view.
property northeast
northeast: ILatLng;
The northeast of the bounds that contains the farLeft, farRight, nearLeft and nearRight. Since the map view is able to rotate, the farRight is not the same as the northeast.
property southwest
southwest: ILatLng;
The southwest of the bounds that contains the farLeft, farRight, nearLeft and nearRight. Since the map view is able to rotate, the nearLeft is not the same as the southwest.
property type
type: string;
constant value :
VisibleRegion
method contains
contains: (LatLng: ILatLng) => boolean;
Returns true if the given lat/lng is in this bounds.
Parameter LatLng
method toString
toString: () => string;
Converts to string {string}
method toUrlValue
toUrlValue: (precision?: number) => string;
Returns a string of the form "lat_sw,lng_sw,lat_ne,lng_ne" for this bounds, where "sw" corresponds to the southwest corner of the bounding box, while "ne" corresponds to the northeast corner of that box.
Parameter precision
{string}
Interfaces
interface CameraPosition
interface CameraPosition<T> {}
property bearing
bearing?: number;
Map orientation
property duration
duration?: number;
The duration of animation in milliseconds
property padding
padding?: number;
Camera padding in pixel
property target
target?: T;
The center location of the camera view.
[usage 1]
let cameraPos: CameraPosition = { target: {lat: ..., lng: ...}, zoom: 10 }
[usage 2] The zoom property is ignored when you specify multiple position
let cameraPos: CameraPosition<ILatLng[]> = { target: [ {lat: ..., lng: ...}, {lat: ..., lng: ...}, {lat: ..., lng: ...} ] }
property tilt
tilt?: number;
View angle
property zoom
zoom?: number;
Zoom level
interface CircleOptions
interface CircleOptions {}
property center
center: ILatLng;
Center position of circle
property clickable
clickable?: boolean;
Set to true to receive the CIRCLE_CLICK event (default: false)
property fillColor
fillColor?: string;
Set the inside color of circle (rgb, rgba, #RRGGBB, "colorname", ...etc)
property radius
radius: number;
Radius of circle in meter
property strokeColor
strokeColor?: string;
Set the stroke color (rgb, rgba, #RRGGBB, "colorname", ...etc)
property strokeWidth
strokeWidth?: number;
Set the stroke width in pixel
property visible
visible?: boolean;
Set to false to hide
property zIndex
zIndex?: number;
Z-index
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface EnvOptions
interface EnvOptions {}
Options for Environment.setEnv()
property API_KEY_FOR_BROWSER_DEBUG
API_KEY_FOR_BROWSER_DEBUG?: string;
property API_KEY_FOR_BROWSER_RELEASE
API_KEY_FOR_BROWSER_RELEASE?: string;
index signature
[key: string]: any;
Accept own properties for future update
interface GeocoderRequest
interface GeocoderRequest {}
property address
address?: string | string[];
The address property or position property is required. You can not specify both property at the same time.
[geocoding usage1] let request: GeocoderRequest = { address: "Los Angeles, California, USA" }
[geocoding usage2] let request: GeocoderRequest = { address: [ "Los Angeles, California, USA", "San Francisco, California, USA", ] }
property position
position?: ILatLng | ILatLng[];
[reverse-geocoding usage1] let request: GeocoderRequest = { position: {"lat": 37.421655, "lng": -122.085637} }
[reverse-geocoding usage2] let request: GeocoderRequest = { position: [ {"lat": 37.421655, "lng": -122.085637}, {"lat": 37.332, "lng": -122.030781} ] }
interface GeocoderResult
interface GeocoderResult {}
property adminArea
adminArea?: string;
property country
country?: string;
property countryCode
countryCode?: string;
property extra
extra?: { featureName?: string; lines?: string[]; permises?: string; phone?: string; url?: string;};
property locale
locale?: string;
property locality
locality?: string;
property position
position?: ILatLng;
property postalCode
postalCode?: string;
property subAdminArea
subAdminArea?: string;
property subLocality
subLocality?: string;
property subThoroughfare
subThoroughfare?: string;
property thoroughfare
thoroughfare?: string;
interface GoogleMapControlOptions
interface GoogleMapControlOptions {}
property compass
compass?: boolean;
Turns the compass on or off.
property indoorPicker
indoorPicker?: boolean;
Turns the indoor picker on or off.
property mapToolbar
mapToolbar?: boolean;
**Android** Turns the map toolbar on or off.
property myLocation
myLocation?: boolean;
Turns the myLocation control(blue dot) on or off. If turns on this control, the application displays a permission dialog to obtain the geolocation data.
property myLocationButton
myLocationButton?: boolean;
Turns the myLocation button on or off. If turns on this button, the application displays a permission dialog to obtain the geolocation data.
property zoom
zoom?: boolean;
**Android** Turns the zoom controller on or off.
index signature
[key: string]: any;
Accept extra properties for future updates
interface GoogleMapGestureOptions
interface GoogleMapGestureOptions {}
property rotate
rotate?: boolean;
Set false to disable the rotate gesture (default: true)
property scroll
scroll?: boolean;
Set false to disable the scroll gesture (default: true)
property tilt
tilt?: boolean;
Set false to disable the tilt gesture (default: true)
property zoom
zoom?: boolean;
Set false to disable the zoom gesture (default: true)
index signature
[key: string]: any;
Accept extra properties for future updates
interface GoogleMapOptions
interface GoogleMapOptions {}
property camera
camera?: CameraPosition<any>;
Initial camera position [options]
property controls
controls?: GoogleMapControlOptions;
controls [options]
property gestures
gestures?: GoogleMapGestureOptions;
gestures [options]
property mapType
mapType?: MapType | string;
mapType [options]
property preferences
preferences?: GoogleMapPreferenceOptions;
preferences [options]
property styles
styles?: any[];
Map styles [options] https://developers.google.com/maps/documentation/javascript/style-reference
index signature
[key: string]: any;
Accept extra properties for future updates
interface GoogleMapPaddingOptions
interface GoogleMapPaddingOptions {}
interface GoogleMapPreferenceOptions
interface GoogleMapPreferenceOptions {}
property building
building?: boolean;
Turns the 3D buildings layer on or off.
property gestureBounds
gestureBounds?: ILatLng[];
Sets the bounds limit for user panning gesture.
property padding
padding?: GoogleMapPaddingOptions;
Paddings of controls.
property zoom
zoom?: GoogleMapZoomOptions;
Minimum and maximum zoom levels for zooming gestures.
index signature
[key: string]: any;
Accept extra properties for future updates
interface GoogleMapZoomOptions
interface GoogleMapZoomOptions {}
interface GroundOverlayOptions
interface GroundOverlayOptions {}
property bearing
bearing?: number;
Bearing
property bounds
bounds: ILatLng[];
Bounds, array of ILatLng
property clickable
clickable?: boolean;
Set to true to receive the GROUND_OVERLAY_CLICK event (default: false)
property opacity
opacity?: number;
Opacity. From 0.0 to 1.0 .
property url
url: string;
URL of overlay
property visible
visible?: boolean;
Set to false to hide
property zIndex
zIndex?: number;
Z-index
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface ILatLngBounds
interface ILatLngBounds {}
interface KmlOverlayOptions
interface KmlOverlayOptions {}
Options for map.addKmlOverlay() method
property clickable
clickable?: boolean;
property icon
icon?: string | MarkerIcon;
property suppressInfoWindows
suppressInfoWindows?: boolean;
property url
url: string;
index signature
[key: string]: any;
Accept own properties for future update
interface MarkerClusterIcon
interface MarkerClusterIcon {}
property anchor
anchor?: any;
anchor position of the marker
property label
label?: MarkerLabel;
label option for clustered marker
property max
max?: number;
Maximum number of clustering
property min
min?: number;
Minimum number of clustering
property size
size?: { width?: number; height?: number;};
icon size
property url
url: string;
icon url
interface MarkerClusterOptions
interface MarkerClusterOptions {}
property boundsDraw
boundsDraw?: boolean;
Draw a rectangle that contains all locations of clustered when you tap on a cluster marker. (default: true)
property icons
icons: MarkerClusterIcon[];
Conditions of clustering [ {icon: "assets/small.png", min: 2, max: 10}, {icon: "assets/middle.png", min: 11, max: 30}, {icon: "assets/large.png", min: 31} ]
property markers
markers: MarkerOptions[];
Position list [ {title: "store A", position: {lat: ..., lng: ...}}, {title: "store B", position: {lat: ..., lng: ...}}, {title: "store C", position: {lat: ..., lng: ...}} ]
property maxZoomLevel
maxZoomLevel?: number;
Maximum zoom level of clustering (default: 15, max: 18)
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface MarkerIcon
interface MarkerIcon {}
interface MarkerLabel
interface MarkerLabel {}
interface MarkerOptions
interface MarkerOptions {}
property anchor
anchor?: number[];
Specify the anchor of icon image
property animation
animation?: string;
Which animation to play when marker is added to a map.
property disableAutoPan
disableAutoPan?: boolean;
Set to true to disable auto panning when the marker is clicked.
property draggable
draggable?: boolean;
Set true if you want to enable to drag the marker. (Default: false) Important! Drag starts after long pressed on the marker.
property flat
flat?: boolean;
Set true if you want to use a flat marker. (Default: false)
property icon
icon?: any;
The icon image url or properties. Also you can specify HTML Color values. Alternatively you can specify the image as Base64
property infoWindowAnchor
infoWindowAnchor?: number[];
Specify the anchor of the InfoWindow
property position
position: ILatLng;
The position of the marker.
property rotation
rotation?: number;
Set rotation angle. (Default: 0)
property snippet
snippet?: string;
The snippet of the infoWindow.
property styles
styles?: any;
Specify the options for title. This property work for normal InfoWindow.
property title
title?: string;
The content of the infoWindow.
property visible
visible?: boolean;
Set false if you want to hide. (Default: true)
property zIndex
zIndex?: number;
Higher zIndex value overlays will be drawn on top of lower zIndex value tile layers and overlays.
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface MyLocation
interface MyLocation {}
property accuracy
accuracy?: any;
property altitude
altitude?: any;
property bearing
bearing?: number;
property elapsedRealtimeNanos
elapsedRealtimeNanos?: any;
property hashCode
hashCode?: any;
property latLng
latLng?: LatLng;
property provider
provider?: any;
property speed
speed?: number;
property time
time?: string;
interface MyLocationOptions
interface MyLocationOptions {}
property enableHighAccuracy
enableHighAccuracy?: boolean;
Set true if you want to try to use GPS mandatory. In false, the plugin try to use GPS and network. (default: false)
interface PolygonOptions
interface PolygonOptions {}
property clickable
clickable?: boolean;
Set true if you want to receive the POLYGON_CLICK event (default: false)
property fillColor
fillColor?: string;
Set the inside color of polygon (rgb, rgba, #RRGGBB, "colorname", ...etc)
property geodesic
geodesic?: boolean;
Set true if you want to draw the curve polygon based on the earth (default: false)
property holes
holes?: ILatLng[][];
Pass ILatLng[][] to create holes in polygon
property points
points: ILatLng[];
Pass ILatLng[] to specify the vertixes. You need to contain two points at least.
property strokeColor
strokeColor?: string;
Set the stroke color (rgb, rgba, #RRGGBB, "colorname", ...etc)
property strokeWidth
strokeWidth?: number;
Set the stroke width in pixel
property visible
visible?: boolean;
Set false if you want to create invisible polygon (Invisible polygon is not clickable, default true)
property zIndex
zIndex?: number;
Hierarchy z-index
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface PolylineOptions
interface PolylineOptions {}
property clickable
clickable?: boolean;
Set true if you want to receive the POLYLINE_CLICK event (default: false)
property color
color?: string;
Set the stroke color (rgb, rgba, #RRGGBB, "colorname", ...etc)
property geodesic
geodesic?: boolean;
Set true if you want to draw the curve polyline based on the earth (default: false)
property points
points: ILatLng[];
Pass ILatLng[] to specify the vertixes. You need to contain two points at least.
property visible
visible?: boolean;
Set false if you want to create invisible polyline (Invisible polyline is not clickable, default true)
property width
width?: number;
Set the stroke width in pixel
property zIndex
zIndex?: number;
Hierarchy z-index
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface SetPovOption
interface SetPovOption {}
interface StreetViewCameraPano
interface StreetViewCameraPano {}
interface StreetViewCameraPosition
interface StreetViewCameraPosition {}
interface StreetViewControlOptions
interface StreetViewControlOptions {}
property navigation
navigation?: boolean;
property streetNames
streetNames?: boolean;
interface StreetViewGestureOptions
interface StreetViewGestureOptions {}
interface StreetViewLocation
interface StreetViewLocation {}
interface StreetViewNavigationLink
interface StreetViewNavigationLink {}
interface StreetViewOptions
interface StreetViewOptions {}
property camera
camera?: StreetViewCameraPano | StreetViewCameraPosition;
property controls
controls?: StreetViewControlOptions;
controls [options]
property gestures
gestures?: StreetViewGestureOptions;
gestures [options]
index signature
[key: string]: any;
Accept extra properties for future updates
interface StreetViewSetPositionOption
interface StreetViewSetPositionOption {}
interface TileOverlayOptions
interface TileOverlayOptions {}
property debug
debug?: boolean;
Set true if you want to display the tile information over the tile images.
property getTile
getTile: (x: number, y: number, zoom: number) => string;
This callback must Returns string of image URL, or Promise. If no tile, you need to Returns null.
property opacity
opacity?: number;
Default: 1.0
property tileSize
tileSize?: number;
Default: 512px
property visible
visible?: boolean;
Set false if you want to create invisible tilelayer (default true)
property zIndex
zIndex?: number;
Hierarchy z-index of tilelayer
index signature
[key: string]: any;
Accept own properties You can get the property later using
get()
method.
interface ToDataUrlOptions
interface ToDataUrlOptions {}
property uncompress
uncompress?: boolean;
True if you want get high quality map snapshot
Type Aliases
type MapType
type MapType = | 'MAP_TYPE_NORMAL' | 'MAP_TYPE_ROADMAP' | 'MAP_TYPE_SATELLITE' | 'MAP_TYPE_HYBRID' | 'MAP_TYPE_TERRAIN' | 'MAP_TYPE_NONE';
Package Files (1)
Dependencies (0)
No dependencies.
Dev Dependencies (0)
No dev dependencies.
Peer Dependencies (2)
Badge
To add a badge like this oneto your package's README, use the codes available below.
You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@ionic-native/google-maps
.
- Markdown[![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@ionic-native/google-maps)
- HTML<a href="https://www.jsdocs.io/package/@ionic-native/google-maps"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>
- Updated .
Package analyzed in 7092 ms. - Missing or incorrect documentation? Open an issue for this package.