You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[maps-sdk-android] Expose new queryRenderedRasterValue API in Android SDK (#9435)
## Summary
Exposes the `queryRenderedRasterValues` API to allow querying raster
values at a specific screen coordinate. This enables developers to
retrieve raster layer data at any point on the rendered map.
## Changes
### Core API (`maps-sdk`)
- **MapboxMap**: Added `queryRenderedRasterValues()` method with
callback-based API
- **NativeMapImpl**: Implemented bridge to native map functionality
- **Coroutine Support**: Added suspend function extension in
`MapFeatureQueryDelegateExt.kt`
- **Delegate Interface**: Extended `MapFeatureQueryDelegate` with new
query method
- **Compose Integration (`extension-compose`)": **MapState** -- Added
`queryRenderedRasterValues()` suspend function for Jetpack Compose
integration
### API Surface
- All API tracking files updated (metalava.txt and .api files for both
`maps-sdk`, `sdk-base`, and `extension-compose`)
- Marked as `@MapboxExperimental` to indicate experimental status
### Test
- queryRenderedRasterValues() test added
cc @mapbox/maps-android
cc @mapbox/sdk-ci
cc @mapbox/sdk-platform
GitOrigin-RevId: f3c0b087743b438c124178dd9b52befa77dcbadf
method @com.mapbox.maps.MapboxExperimental public suspend <FS extends com.mapbox.maps.interactions.FeatureState, FSK extends com.mapbox.maps.interactions.FeatureStateKey<FS>> Object? removeFeatureState(com.mapbox.maps.interactions.FeaturesetFeature<FS> featuresetFeature, kotlin.coroutines.Continuation<? super com.mapbox.bindgen.Expected<java.lang.String,com.mapbox.bindgen.None>> = null);
68
69
method @com.mapbox.maps.MapboxExperimental public suspend Object? resetFeatureStates(com.mapbox.maps.interactions.TypedFeaturesetDescriptor<?,?> descriptor, kotlin.coroutines.Continuation<? super com.mapbox.bindgen.Expected<java.lang.String,com.mapbox.bindgen.None>>);
Copy file name to clipboardExpand all lines: extension-compose/api/extension-compose.api
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -86,6 +86,7 @@ public final class com/mapbox/maps/extension/compose/MapState {
86
86
public final fun queryRenderedFeatures (Lcom/mapbox/maps/interactions/TypedFeaturesetDescriptor;Lcom/mapbox/maps/RenderedQueryGeometry;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
87
87
public final fun queryRenderedFeatures (Lcom/mapbox/maps/interactions/TypedFeaturesetDescriptor;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
88
88
public static synthetic fun queryRenderedFeatures$default (Lcom/mapbox/maps/extension/compose/MapState;Lcom/mapbox/maps/interactions/TypedFeaturesetDescriptor;Lcom/mapbox/maps/RenderedQueryGeometry;Lcom/mapbox/maps/extension/style/expressions/generated/Expression;Lkotlin/coroutines/Continuation;ILjava/lang/Object;)Ljava/lang/Object;
89
+
public final fun queryRenderedRasterValues (Lcom/mapbox/maps/ScreenCoordinate;Lcom/mapbox/maps/RenderedRasterQueryOptions;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
89
90
public final fun removeFeatureState (Lcom/mapbox/maps/interactions/FeaturesetFeature;Lcom/mapbox/maps/interactions/FeatureStateKey;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
90
91
public final fun removeFeatureState (Lcom/mapbox/maps/interactions/FeaturesetFeature;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
91
92
public static synthetic fun removeFeatureState$default (Lcom/mapbox/maps/extension/compose/MapState;Lcom/mapbox/maps/interactions/FeaturesetFeature;Lcom/mapbox/maps/interactions/FeatureStateKey;Lkotlin/coroutines/Continuation;ILjava/lang/Object;)Ljava/lang/Object;
Copy file name to clipboardExpand all lines: maps-sdk/api/maps-sdk.api
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -270,6 +270,7 @@ public final class com/mapbox/maps/MapboxMap : com/mapbox/maps/MapboxStyleManage
270
270
public final fun queryRenderedFeatures (Lcom/mapbox/maps/interactions/TypedFeaturesetDescriptor;Lcom/mapbox/maps/RenderedQueryGeometry;Lcom/mapbox/maps/interactions/QueryRenderedFeaturesetFeaturesCallback;)Lcom/mapbox/common/Cancelable;
271
271
public final fun queryRenderedFeatures (Lcom/mapbox/maps/interactions/TypedFeaturesetDescriptor;Lcom/mapbox/maps/interactions/QueryRenderedFeaturesetFeaturesCallback;)Lcom/mapbox/common/Cancelable;
272
272
public static synthetic fun queryRenderedFeatures$default (Lcom/mapbox/maps/MapboxMap;Lcom/mapbox/maps/interactions/TypedFeaturesetDescriptor;Lcom/mapbox/maps/RenderedQueryGeometry;Lcom/mapbox/bindgen/Value;Lcom/mapbox/maps/interactions/QueryRenderedFeaturesetFeaturesCallback;ILjava/lang/Object;)Lcom/mapbox/common/Cancelable;
273
+
public fun queryRenderedRasterValues (Lcom/mapbox/maps/ScreenCoordinate;Lcom/mapbox/maps/RenderedRasterQueryOptions;Lcom/mapbox/maps/QueryRenderedRasterValuesCallback;)Lcom/mapbox/common/Cancelable;
273
274
public fun querySourceFeatures (Ljava/lang/String;Lcom/mapbox/maps/SourceQueryOptions;Lcom/mapbox/maps/QuerySourceFeaturesCallback;)Lcom/mapbox/common/Cancelable;
274
275
public final fun reduceMemoryUse ()V
275
276
public final fun removeFeatureState (Lcom/mapbox/maps/interactions/FeaturesetFeature;)Lcom/mapbox/common/Cancelable;
@@ -637,6 +638,7 @@ public final class com/mapbox/maps/coroutine/MapCameraManagerDelegateExtKt {
637
638
638
639
public final class com/mapbox/maps/coroutine/MapFeatureQueryDelegateExtKt {
639
640
public static final synthetic fun queryRenderedFeatures (Lcom/mapbox/maps/plugin/delegates/MapFeatureQueryDelegate;Lcom/mapbox/maps/RenderedQueryGeometry;Lcom/mapbox/maps/RenderedQueryOptions;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
641
+
public static final synthetic fun queryRenderedRasterValues (Lcom/mapbox/maps/plugin/delegates/MapFeatureQueryDelegate;Lcom/mapbox/maps/ScreenCoordinate;Lcom/mapbox/maps/RenderedRasterQueryOptions;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
640
642
public static final synthetic fun querySourceFeatures (Lcom/mapbox/maps/plugin/delegates/MapFeatureQueryDelegate;Ljava/lang/String;Lcom/mapbox/maps/SourceQueryOptions;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
0 commit comments