MapObjectCollection class abstract

A collection of map objects that can hold any set of MapObject items, including nested collections.

Implemented types

Constructors

MapObjectCollection()

Properties

draggable bool
If true, the map object can be dragged by the user. Default: false.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
parent BaseMapObjectCollection
Returns the collection of map objects that the current map object belongs to.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
userData Object?
getter/setter pairinherited
visible bool
Manages visibility of the object on the map. Default: true.
getter/setter pairinherited
zIndex double
Gets the z-index, which affects:
getter/setter pairinherited

Methods

addCircle(Circle circle) CircleMapObject
Creates a new circle and adds it to the current collection.
addClusterizedPlacemarkCollection(ClusterListener clusterListener) ClusterizedPlacemarkCollection
Creates a new nested collection of clusterized placemarks.
addCollection() MapObjectCollection
Creates a new nested collection of map objects.
addEmptyPlacemark(Point point) PlacemarkMapObject
Creates a new empty placemark and adds it to the current collection.
addEmptyPlacemarks(List<Point> points) List<PlacemarkMapObject>
Creates new empty placemarks and adds them to the current collection.
addListener(MapObjectCollectionListener collectionListener) → void
Adds a listener to track notifications of changes to the collection.
inherited
addPlacemark() PlacemarkMapObject
Creates a new empty placemark and adds it to the current collection.
addPlacemarks(ImageProvider image, IconStyle style, {required List<Point> points}) List<PlacemarkMapObject>
Creates new placemarks and adds them to the current collection. Relevant for Android: this method provides better performance for adding a large number of placemarks than multiple calls of addPlacemark.
addPlacemarkWithAnimatedImageStyle(Point point, AnimatedImageProvider animatedImage, IconStyle style) PlacemarkMapObject
Creates a new placemark with animated icon and adds it to the current collection.
addPlacemarkWithCallback(PlacemarkCreatedCallback placemarkCreatedCallback) PlacemarkMapObject
Creates a new empty placemark and adds it to the current collection. Callback can be used to setup placemark style and position Callback will be called before MapObjectCollectionListener#onMapObjectAdded
addPlacemarkWithImage(Point point, ImageProvider image) PlacemarkMapObject
Creates a new placemark with the default style and adds it to the current collection.
addPlacemarkWithImageStyle(Point point, ImageProvider image, IconStyle style) PlacemarkMapObject
Creates a new placemark and adds it to the current collection. Hint: to add a large amount of placemarks use addPlacemarks method.
addPlacemarkWithPoint(Point point) PlacemarkMapObject
Creates a new placemark with the default icon and style, and adds it to the current collection.
addPlacemarkWithView(Point point, ViewProvider view) PlacemarkMapObject
Creates a new view placemark with default style and adds it to the current collection.
addPlacemarkWithViewStyle(Point point, ViewProvider view, IconStyle style) PlacemarkMapObject
Creates a new view placemark and adds it to the current collection.
addPolygon(Polygon polygon) PolygonMapObject
Creates a new polygon and adds it to the current collection.
addPolyline() PolylineMapObject
Creates a new polyline with an empty geometry and adds it to the current collection.
addPolylineWithGeometry(Polyline polyline) PolylineMapObject
Creates a new polyline and adds it to the current collection.
addTapListener(MapObjectTapListener tapListener) → void
Adds a tap listener to the object.
inherited
clear() → void
Removes all map objects from the collection.
inherited
isValid() bool
Usable only in runWithBlockUi or listener handlers.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
placemarksStyler() PlacemarksStyler
A styler for all placemarks in this collection, including placemarks in child collections.
remove(MapObject mapObject) → void
Removes the given map object from the collection.
inherited
removeListener(MapObjectCollectionListener collectionListener) → void
Removes a listener.
inherited
removeTapListener(MapObjectTapListener tapListener) → void
Removes the tap listener from the object.
inherited
setDragListener(MapObjectDragListener? dragListener) → void
Sets a drag listener for the object. Each object can only have one drag listener.
inherited
setVisible(Animation animation, {required bool visible, Callback? onFinished}) → void
Manages visibility of the object.
inherited
toString() String
A string representation of this object.
inherited
traverse(MapObjectVisitor mapObjectVisitor) → void
Traverses through the collection with a visitor object. Used for iteration over map objects in the collection.
inherited

Operators

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