markers property

MapViewMarkerCollections get markers

Get access to the collections of visible markers.

Markers are custom icons or images displayed at specific map locations. Use this collection to add, remove, and configure markers.

Returns

  • (MapViewMarkerCollections) The marker collections for the view.

See also:

Implementation

MapViewMarkerCollections get markers {
  if (_markers == null) {
    final OperationResult resultString = objectMethod(
      _pointerId,
      'MapViewPreferences',
      'markers',
      dependencyId: _mapPointerId,
    );

    _markers = MapViewMarkerCollections.init(
      resultString['result'],
      _mapId,
      _mapPointerId,
    );
  }
  return _markers!;
}