new Cluster(mc)
Creates a single cluster that manages a group of proximate markers.
Used internally, do not call this constructor directly.
Parameters:
Name | Type | Description |
---|---|---|
mc |
MarkerClusterer | The |
Methods
-
calculateBounds_()
-
Calculates the extended bounds of the cluster with the grid.
-
getCenter()
-
Returns the center of the cluster. You can call this from
aclick
,mouseover
, ormouseout
event handler
for theMarkerClusterer
object.Returns:
The center of the cluster.
- Type
- google.maps.LatLng
-
getMarkers()
-
Returns the array of markers managed by the cluster. You can call this from
aclick
,mouseover
, ormouseout
event handler
for theMarkerClusterer
object.Returns:
The array of markers in the cluster.
- Type
- Array
-
getSize()
-
Returns the number of markers managed by the cluster. You can call this from
aclick
,mouseover
, ormouseout
event handler
for theMarkerClusterer
object.Returns:
The number of markers in the cluster.
- Type
- number
-
isMarkerAlreadyAdded_(marker)
-
Determines if a marker has already been added to the cluster.
Parameters:
Name Type Description marker
google.maps.Marker The marker to check.
Returns:
True if the marker has already been added.
- Type
- boolean
-
updateIcon_()
-
Updates the cluster icon.