ArcGISMapViewController class final

A user interface control that displays two-dimensional (2D) geographic content defined by an ArcGISMap.

An ArcGISMapViewController is a user interface that displays ArcGISMap layers and graphics in 2D. It controls the area (extent) of the ArcGISMap that is visible and supports user interactions such as pan and zoom. A map view also provides access to the underlying layer data in a map.

To display an ArcGISMap, add an ArcGISMapViewController control to your app and assign the map to it. This loads the map and its content, such as a Basemap and collection of operational layers, and displays this content on screen.

User interactions such as pan, zoom, rotate, and identify or selection are supported in the ArcGISMapViewController using touch, mouse, keyboard or pen/pencil. If required, you can override keys, clicks, and gestures to provide a specific user experience.

The visible area (Viewpoint) of the ArcGISMapViewController is defined by the visible extent the map. To determine the current visible area or the center point and scale of an ArcGISMapViewController, call GeoViewController.getCurrentViewpoint. Make sure that any user-initiated or programmatic navigation is complete before getting the current Viewpoint by calling GeoViewController.isNavigating.

You can programmatically set the visible area by specifying a viewpoint. For example, ArcGISMapViewController.setViewpointGeometry sets the visible area to the extent of a provided geometry, and ArcGISMapViewController.setViewpointCenter centers the map view at a given point. Any geometries passed to these methods are automatically projected to match the SpatialReference of the map view's ArcGISMap, if required.

In an MVC architecture, the ArcGISMapViewController represents the View tier. The Model tier is represented by the ArcGISMap object which can provide a collection of operational layers and a Basemap. You can only set one ArcGISMap per ArcGISMapViewController, but you can swap the ArcGISMapViewController.arcGISMap with another when the application is running.

See Map view for more information.

Inheritance

Properties

allowMagnifierToPanMap bool
True if the ArcGISMapViewController is panned automatically when the magnifier gets near the edge of the ArcGISMapViewController, otherwise false.
getter/setter pair
arcGISMap ArcGISMap?
The map that the ArcGISMapViewController is displaying.
getter/setter pair
attributionText String
The attribution text for the data that is currently displayed in the GeoViewController.
no setterinherited
backgroundGrid BackgroundGrid
The background grid that an ArcGISMap is displayed on top of.
getter/setter pair
drawStatus DrawStatus
The current drawing status of the content displayed in the GeoViewController.
no setterinherited
graphicsOverlays List<GraphicsOverlay>
A collection of GraphicsOverlay objects used to display graphics on top of the view's content.
no setterinherited
grid Grid?
A coordinate system grid to display on top of the ArcGISMapViewController.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
interactionOptions ArcGISMapViewInteractionOptions
Options for controlling how user interactions behave.
no setter
isAttributionTextVisible bool
True if attribution text is visible in the GeoViewController, false otherwise.
getter/setter pairinherited
isNavigating bool
True if the GeoViewController is animating a viewpoint change or a navigation gesture is in progress, otherwise false.
no setterinherited
isWrapAroundEnabled bool
True if continuous panning across the international date line is enabled in the GeoViewController, false otherwise.
no setterinherited
labeling ViewLabelProperties
The view label properties.
getter/setter pairinherited
locationDisplay LocationDisplay
The location display manages and renders the device's current location on an ArcGISMapViewController using a data source, such as a GPS sensor.
getter/setter pair
magnifierEnabled bool
True if the magnifier is enabled, otherwise false.
getter/setter pair
onAttributionChanged Stream<String>
Invokes the callback when the attribution text of the GeoViewController changes.
no setterinherited
onDrawStatusChanged Stream<DrawStatus>
Invokes the callback when the draw status of the GeoViewController changes.
no setterinherited
onLayerViewStateChanged Stream<({Layer layer, LayerViewState layerViewState})>
Invokes the callback when the layer view state of any layer in the GeoViewController changes.
no setterinherited
onNavigationChanged Stream<bool>
Invokes the callback when the navigation state of the GeoViewController changes.
no setterinherited
onRotationChanged Stream<double>
Invokes the callback when rotation of the ArcGISMapViewController changes.
no setter
onScaleChanged Stream<double>
Invokes the callback when the scale of the ArcGISMapViewController changes.
no setter
onSpatialReferenceChanged Stream<SpatialReference?>
Invokes the callback when the spatial reference of the GeoViewController changes.
no setterinherited
onTimeExtentChanged Stream<TimeExtent?>
Invokes the callback when the time extent of the GeoViewController changes.
no setterinherited
onViewpointChanged Stream<void>
Invokes the callback when the viewpoint of the GeoViewController has changed.
no setterinherited
rotation double
The rotation angle of the ArcGISMap in degrees from its north-south direction.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scale double
The scale of the ArcGISMapViewController.
no setter
selectionProperties SelectionProperties
The selection properties for all graphic overlays and selectable layers within the GeoViewController.
getter/setter pairinherited
spatialReference SpatialReference?
The spatial reference defines the coordinate system used by the map or scene in the GeoViewController.
no setterinherited
timeExtent TimeExtent?
The current TimeExtent of the GeoViewController.
getter/setter pairinherited
unitsPerDip double
The size of each device-independent pixel (DIP) in map units.
no setter
visibleArea Polygon?
The map view's visible area.
no setter
wrapAroundMode WrapAroundMode
Indicates whether continuous panning across the international date line is enabled.
getter/setter pair

Methods

dispose() → void
This function cleans up properties of this controller before garbage collection happens.
override
exportImage() Future<ArcGISImage>
Exports an image snapshot of the current GeoViewController.
inherited
exportImageCancelable() CancelableOperation<ArcGISImage>
Cancelable version of exportImage. See that method for more information.
inherited
getCurrentViewpoint({required ViewpointType viewpointType}) Viewpoint?
Retrieves the current Viewpoint of the GeoViewController.
inherited
getLayerViewState({required Layer layer}) LayerViewState?
Retrieves the layer's state in the GeoViewController.
inherited
identifyGraphicsOverlay(GraphicsOverlay graphicsOverlay, {required Offset screenPoint, required double tolerance, int? maximumResults = 1}) Future<IdentifyGraphicsOverlayResult>
Identifies a limited number of graphics in the specified graphics overlay, at the given screen point.
inherited
identifyGraphicsOverlayCancelable(GraphicsOverlay graphicsOverlay, {required Offset screenPoint, required double tolerance, int? maximumResults = 1}) CancelableOperation<IdentifyGraphicsOverlayResult>
Cancelable version of identifyGraphicsOverlay. See that method for more information.
inherited
identifyGraphicsOverlays({required Offset screenPoint, required double tolerance, int? maximumResultsPerOverlay = 1}) Future<List<IdentifyGraphicsOverlayResult>>
Identifies a limited number of graphics in all graphics overlays, at the given screen point.
inherited
identifyGraphicsOverlaysCancelable({required Offset screenPoint, required double tolerance, int? maximumResultsPerOverlay = 1}) CancelableOperation<List<IdentifyGraphicsOverlayResult>>
Cancelable version of identifyGraphicsOverlays. See that method for more information.
inherited
identifyLayer(Layer layer, {required Offset screenPoint, required double tolerance, int? maximumResults = 1}) Future<IdentifyLayerResult>
Identifies a limited number of geoelements in the specified layer or sublayer, at the given screen point.
inherited
identifyLayerCancelable(Layer layer, {required Offset screenPoint, required double tolerance, int? maximumResults = 1}) CancelableOperation<IdentifyLayerResult>
Cancelable version of identifyLayer. See that method for more information.
inherited
identifyLayers({required Offset screenPoint, required double tolerance, int? maximumResultsPerLayer = 1}) Future<List<IdentifyLayerResult>>
Identifies a limited number of geoelements at the given screen point, in each identifiable layer or sublayer in the GeoViewController's ArcGISMap or ArcGISScene.
inherited
identifyLayersCancelable({required Offset screenPoint, required double tolerance, int? maximumResultsPerLayer = 1}) CancelableOperation<List<IdentifyLayerResult>>
Cancelable version of identifyLayers. See that method for more information.
inherited
locationToScreen({required ArcGISPoint arcGISMapPoint}) Offset
Converts a location in map coordinates to screen coordinates relative to the upper-left corner of the map view.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
screenToLocation({required Offset screen}) ArcGISPoint?
Converts screen coordinates relative to the upper-left corner of the map view to a location in map coordinates.
setBookmark(Bookmark bookmark) Future<bool>
Sets the Viewpoint of the GeoViewController to the Bookmark.viewpoint.
inherited
setBookmarkCancelable(Bookmark bookmark) CancelableOperation<bool>
Cancelable version of setBookmark. See that method for more information.
inherited
setViewpoint(Viewpoint viewpoint) → void
Pan or zoom the GeoViewController to the specified Viewpoint location.
inherited
setViewpointAnimated(Viewpoint viewpoint, {double? duration}) Future<bool>
Pan or zoom the GeoViewController using animation to the specified Viewpoint location. Animation takes place over the specified duration.
inherited
setViewpointAnimatedCancelable(Viewpoint viewpoint, {double? duration}) CancelableOperation<bool>
Cancelable version of setViewpointAnimated. See that method for more information.
inherited
setViewpointCenter(ArcGISPoint center, {double? scale}) Future<bool>
Centers the map view at the provided center point and zooms to the given scale.
setViewpointCenterCancelable(ArcGISPoint center, {double? scale}) CancelableOperation<bool>
Cancelable version of setViewpointCenter. See that method for more information.
setViewpointGeometry(Geometry boundingGeometry, {double? paddingInDiPs}) Future<bool>
Zooms and pans the map view to the extent of the provided geometry with additional padding.
setViewpointGeometryCancelable(Geometry boundingGeometry, {double? paddingInDiPs}) CancelableOperation<bool>
Cancelable version of setViewpointGeometry. See that method for more information.
setViewpointRotation({required double angleDegrees}) Future<bool>
Rotates the map view to the provided angle.
setViewpointRotationCancelable({required double angleDegrees}) CancelableOperation<bool>
Cancelable version of setViewpointRotation. See that method for more information.
setViewpointScale({required double scale}) Future<bool>
Zooms the map view to the provided scale around its current center point.
setViewpointScaleCancelable({required double scale}) CancelableOperation<bool>
Cancelable version of setViewpointScale. See that method for more information.
setViewpointWithDurationAndCurve({required Viewpoint viewpoint, required double durationSeconds, required AnimationCurve curve}) Future<bool>
Animates the display to the new viewpoint using the provided animation curve. The AnimationCurve defines the animation easing function.
setViewpointWithDurationAndCurveCancelable({required Viewpoint viewpoint, required double durationSeconds, required AnimationCurve curve}) CancelableOperation<bool>
Cancelable version of setViewpointWithDurationAndCurve. See that method for more information.
toString() String
A string representation of this object.
inherited

Operators

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