identifyGraphicsOverlay

suspend fun identifyGraphicsOverlay(graphicsOverlay: GraphicsOverlay, screenCoordinate: ScreenCoordinate, tolerance: Double, returnPopupsOnly: Boolean): Result<IdentifyGraphicsOverlayResult>

Initiate an Identify operation on the specified graphicsOverlay.

The tolerance parameter determines the extent of the region used during the identify operation. This overload will return the visible topmost graphic. A tolerance of 0 tests just the physical pixel at screenCoordinate. Tolerance values above 0 are in DIPs and specify a circular region centered on screenCoordinate, with radius equal to tolerance. The maximum allowed tolerance value is 100 DIPs, resulting in an identify circle of diameter 200 DIPs.

The returnPopupsOnly parameter controls what properties are populated in the IdentifyGraphicsOverlayResult instance that is returned by the identify operation:

Return

A Result containing an IdentifyGraphicsOverlayResult, or failure

Since

200.0.0

Parameters

graphicsOverlay

overlay on which to run the identify

screenCoordinate

location at which to run identify in screen coordinates

tolerance

extent of the region used during the identify operation

returnPopupsOnly

whether the graphics property of the result is populated


suspend fun identifyGraphicsOverlay(graphicsOverlay: GraphicsOverlay, screenCoordinate: ScreenCoordinate, tolerance: Double, returnPopupsOnly: Boolean, maximumResults: Int): Result<IdentifyGraphicsOverlayResult>

Initiate an Identify operation on the specified graphicsOverlay.

The tolerance parameter determines the extent of the region used during the identify operation. Any graphics that intersect this test region when rendered are returned, up to the maximumResults limit. A tolerance of 0 tests just the physical pixel at screenCoordinate. Tolerance values above 0 are in DIPs and specify a circular region centered on screenCoordinate, with radius equal to tolerance. The maximum allowed tolerance value is 100 DIPs, resulting in an identify circle of diameter 200 DIPs.

The returnPopupsOnly parameter controls what properties are populated in the IdentifyGraphicsOverlayResult instance that is returned by the identify operation:

Return

A Result containing an IdentifyGraphicsOverlayResult, or failure

Since

200.0.0

Parameters

graphicsOverlay

overlay on which to run the identify

screenCoordinate

location at which to run identify in screen coordinates

tolerance

extent of the region used during the identify operation

returnPopupsOnly

whether the graphics property of the result is populated

maximumResults

maximum size of the result set of ref@Graphic to return. -1 indicates unlimited results