querySourceFeatures method

Future<List<SourceFeature>> querySourceFeatures(
  1. String sourceId, {
  2. SourceFeatureQueryOptions? options,
})

Finds the features of the source named sourceId.

The query covers only the tiles that the source has loaded for the current view. A source loads tiles only while a visible layer uses it.

See mln_render_session_query_source_features in the C API reference.

Implementation

Future<List<SourceFeature>> querySourceFeatures(
  String sourceId, {
  SourceFeatureQueryOptions? options,
}) => _queryList(
  _resultSourceFeature,
  (arena, completion) => raw.mln_render_session_query_source_features(
    _handle.raw,
    nativeStringView(sourceId, arena).value,
    options == null
        ? nullptr
        : _writeSourceFeatureQueryOptions(options, arena),
    completion,
    nativeDiagnostic,
  ),
);