ClusterManager<T extends ClusterItem> class

Constructors

ClusterManager(Iterable<T> _items, void updateMarkers(Set<Marker>), {Future<Marker> markerBuilder(Cluster<T>)?, List<double> levels = const [1, 4.25, 6.75, 8.25, 11.5, 14.5, 16.0, 16.5, 20.0], double extraPercent = 0.5, int maxItemsForMaxDistAlgo = 200, ClusterAlgorithm clusterAlgorithm = ClusterAlgorithm.geoHash, MaxDistParams? maxDistParams, double? stopClusteringZoom})

Properties

clusterAlgorithm ClusterAlgorithm
final
extraPercent double
Extra percent of markers to be loaded (ex : 0.2 for 20%)
final
hashCode int
The hash code for this object.
no setterinherited
items Iterable<T>
List of items
no setter
levels List<double>
Zoom levels configuration
final
markerBuilder Future<Marker> Function(Cluster<T>)
Method to build markers
final
maxDistParams MaxDistParams?
final
maxItemsForMaxDistAlgo int
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stopClusteringZoom double?
Zoom level to stop cluster rendering
final
updateMarkers → void Function(Set<Marker>)
Function to update Markers on Google Map
final

Methods

addItem(ClusterItem newItem) → void
Add on cluster item
getMarkers() Future<List<Cluster<T>>>
Retrieve cluster markers
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onCameraMove(CameraPosition position, {bool forceUpdate = false}) → void
Method called on camera move
setItems(List<T> newItems) → void
Update all cluster items
setMapId(int mapId, {bool withUpdate = true}) Future<void>
Set Google Map Id for the cluster manager
toString() String
A string representation of this object.
inherited
updateMap() → void
Method called on map update to update cluster. Can also be manually called to force update.

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

precision → const int
Precision of the geohash