A layer that can visualize feature data. More...
Header: | #include <FeatureLayer.h> |
Since: | Esri::ArcGISRuntime 100.0 |
Inherits: | Esri::ArcGISRuntime::Layer, Esri::ArcGISRuntime::PopupSource, Esri::ArcGISRuntime::TimeAware, Esri::ArcGISRuntime::FloorAware, and Esri::ArcGISRuntime::SnapSource |
Inherited By: |
Public Functions
FeatureLayer(Esri::ArcGISRuntime::FeatureTable *featureTable, QObject *parent = nullptr) | |
FeatureLayer(Esri::ArcGISRuntime::Item *item, qint64 serviceLayerId, QObject *parent = nullptr) | |
FeatureLayer(Esri::ArcGISRuntime::Item *item, QObject *parent = nullptr) | |
virtual | ~FeatureLayer() override |
void | clearSelection() |
QString | definitionExpression() const |
Esri::ArcGISRuntime::DisplayFilterDefinition * | displayFilterDefinition() const |
Esri::ArcGISRuntime::FeatureReduction * | featureReduction() const |
Esri::ArcGISRuntime::FeatureTable * | featureTable() const |
bool | isLabelsEnabled() const |
bool | isScaleSymbols() const |
Esri::ArcGISRuntime::LabelDefinitionListModel * | labelDefinitions() const |
quint64 | refreshInterval() const |
Esri::ArcGISRuntime::Renderer * | renderer() const |
Esri::ArcGISRuntime::FeatureRenderingMode | renderingMode() const |
void | resetFeaturesVisible() |
void | resetRenderer() |
Esri::ArcGISRuntime::LayerSceneProperties | sceneProperties() const |
void | selectFeature(Esri::ArcGISRuntime::Feature *feature) |
void | selectFeatures(const QList<Esri::ArcGISRuntime::Feature *> &features) |
QFuture<Esri::ArcGISRuntime::FeatureQueryResult *> | selectFeaturesAsync(const Esri::ArcGISRuntime::QueryParameters ¶meters, Esri::ArcGISRuntime::SelectionMode mode, QObject *parent = nullptr) |
QFuture<Esri::ArcGISRuntime::FeatureQueryResult *> | selectedFeaturesAsync(QObject *parent = nullptr) |
qint64 | serviceLayerId() const |
void | setDefinitionExpression(const QString &expression) |
void | setDisplayFilterDefinition(Esri::ArcGISRuntime::DisplayFilterDefinition *displayFilterDefinition) |
void | setFeatureReduction(Esri::ArcGISRuntime::FeatureReduction *featureReduction) |
void | setFeatureVisible(Esri::ArcGISRuntime::Feature *feature, bool visible) |
void | setFeaturesVisible(const QList<Esri::ArcGISRuntime::Feature *> &features, bool visible) |
void | setLabelsEnabled(bool enabled) |
void | setRefreshInterval(quint64 milliseconds) |
void | setRenderer(Esri::ArcGISRuntime::Renderer *renderer) |
void | setRenderingMode(Esri::ArcGISRuntime::FeatureRenderingMode renderingMode) |
void | setScaleSymbols(bool scaleSymbols) |
void | setSceneProperties(const Esri::ArcGISRuntime::LayerSceneProperties &sceneProperties) |
void | setTilingMode(Esri::ArcGISRuntime::FeatureTilingMode tilingMode) |
Esri::ArcGISRuntime::FeatureTilingMode | tilingMode() const |
QJsonObject | unknownJson() const |
void | unselectFeature(Esri::ArcGISRuntime::Feature *feature) |
void | unselectFeatures(const QList<Esri::ArcGISRuntime::Feature *> &features) |
QJsonObject | unsupportedJson() const |
Reimplemented Public Functions
virtual Esri::ArcGISRuntime::LayerFloorDefinition * | floorDefinition() const override |
virtual Esri::ArcGISRuntime::TimeExtent | fullTimeExtent() const override |
virtual bool | isPopupEnabled() const override |
virtual bool | isSupportsTimeFiltering() const override |
virtual bool | isTimeFilteringEnabled() const override |
virtual Esri::ArcGISRuntime::PopupDefinition * | popupDefinition() const override |
virtual void | setFloorDefinition(Esri::ArcGISRuntime::LayerFloorDefinition *floorDefinition) override |
virtual void | setPopupDefinition(Esri::ArcGISRuntime::PopupDefinition *popupDefinition) override |
virtual void | setPopupEnabled(bool popupEnabled) override |
virtual void | setTimeFilteringEnabled(bool timeFilteringEnabled) override |
virtual void | setTimeOffset(const Esri::ArcGISRuntime::TimeValue &timeOffset) override |
virtual Esri::ArcGISRuntime::TimeValue | timeInterval() const override |
virtual Esri::ArcGISRuntime::TimeValue | timeOffset() const override |
Signals
void | fullTimeExtentChanged() |
Detailed Description
Feature layers can display Feature data from a range of online feature table sources, such as ServiceFeatureTable, WfsFeatureTable or OgcFeatureCollectionTable source, and offline sources such as GeodatabaseFeatureTable, ShapefileFeatureTable, or GeoPackageFeatureTable. You can construct a feature layer object using these feature table sources or you can obtain it directly from a map or scene's collection of GeoModel::operationalLayers.
Feature layers can also be used to store features associated with a utility network. To display features in a FeatureCollectionTable, use FeatureCollectionLayer instead.
Feature layers can be used to display, select, and query features in a layer. Individual features can be queried and filtered based on spatial queries or SQL queries. String comparisons for features queried in service feature tables are case insensitive.
If the underlying feature service or table supports editing, you can use it with a feature layer as a basis for editing geometry, attributes, and attachments.
The features in a feature layer are retrieved as needed by the app. Features can be downloaded from a sync-enabled feature service when the device is connected and cached locally for use when the device is offline. Edits can then be synchronized back to the service.
Functional characteristics
The following sources can be rendered using a feature layer:
- Feature service - backed by a ServiceFeatureTable. The feature data from the service is cached locally in the table. New features are retrieved automatically when you navigate the map. The local table cache is discarded when the layer is disposed. If sync is enabled, features can be created, edited, and synchronized back to the server.
- Geodatabase - backed by a GeodatabaseFeatureTable. The geodatabase can be a replica of a feature service, which allows synchronizing with the feature service, or taking the content of a feature service offline. Use GeodatabaseSyncTask to synchronize the geodatabase with the service. The geodatabase can also be a mobile geodatabase created by ArcGIS Pro. These geodatabases cannot be synced and use a default renderer.
- Shapefile - backed by a ShapefileFeatureTable. Use a feature layer to show the contents of a shapefile (.shp).
- Geopackage - backed by a GeoPackageFeatureTable. This uses a feature layer to render the tables in a GeoPackage (.gpkg). A GeoPackage is a data source that conforms to the OGC GeoPackage specification. Geopackage feature tables can be edited and saved, but do not support sync, because there is no backing feature service. This API supports GeoPackage versions 1.0, 1.1, and 1.2.
- Web Feature Service (WFS) - backed by a WfsFeatureTable. You can populate the table using QueryParameters or raw XML-encoded GetFeature queries. A WFS feature table only supports the manual cache feature request mode. This API supports OGC WFS versions 2.0.0 and 2.0.2. WFS server implementations are inconsistent in how they expect coordinates to be formatted. Some return and expect coordinates in (x,y) order, while others expect (y,x). This API anticipates the order but you can configure it with the WfsFeatureTable::axisOrder and WfsFeatureTable::filterAxisOrder.
- OGC API Features - Backed by an OgcFeatureCollectionTable. You can populate the table using QueryParameters. An OCG feature collection table only supports the manual cache feature request mode. This API supports OGC API - Features - Part 1 and OGC API - Features - Part 2.
The features displayed in a FeatureLayer are automatically projected to match the map or scene's GeoModel::spatialReference, if necessary. Local tables cannot be projected automatically.
FeatureLayer does not expose every value defined in the web map or web scene specification. You can obtain a dictionary of unsupported values from unsupportedJson. The FeatureLayer also provides unknownJson to return JSON that is not recognized in the web map or web scene specification.
Performance characteristics
The feature layer offers excellent display performance when zooming and panning the map within the extent of locally cached features. This is because features are drawn natively and full feature information is cached locally in a geodatabase, shapefile, or GeoPackage. Querying features is also efficient, enabling app functions such as real-time updates of query results in a map.
Initially, a local cache must be created. The initial download to the device may require extensive network usage and subsequent local device storage. App memory usage increases with the number and complexity of the features cached. You can eliminate the network usage by provisioning the cache directly to the device in advance.
If the feature layer's FeatureTable is backed by a service it has three feature request modes (FeatureRequestMode) that control how and when features are requested from the service:
- On interaction cache - Features are requested automatically for the visible map or scene extent. As the user pans and zooms, features are cached locally. If the user returns to an area where features have already been loaded, the table won't need to download those features again.
- Manual cache - Features are manually populated using a call to ServiceFeatureTable::populateFromServiceAsync(const Esri::ArcGISRuntime::QueryParameters&, bool, const QStringList&, QObject*). Once populated, all queries are made against the local table only. ServiceFeatureTable::populateFromServiceAsync(const Esri::ArcGISRuntime::QueryParameters&, bool, const QStringList&, QObject*) can be called again to retrieve more features from the service.
- On interaction, no cache - Features are requested automatically for the visible map extent. As the user pans and zooms, features outside the visible extent are not cached and must be downloaded again each time.
Relevant samples:
- Add features (feature service): Add features to a feature layer.
- Add features with contingent values: Create and add features whose attribute values satisfy a predefined set of contingencies.
- Apply unique values with alternate symbols: Apply a unique value with alternate symbols at different scales.
- Browse WFS layers: Browse a WFS service for layers and add them to the map.
- Configure clusters: Add client side feature reduction on a point feature layer that is not pre-configured with clustering.
- Control time extent using time slider: This sample demonstrates how to use the time slider from the toolkit to visualize temporal data by applying a specific time extent.
- Create mobile geodatabase: Create and share a mobile geodatabase.
- Create symbol styles from web styles: Create symbol styles from a style file hosted on a portal.
- Delete features (feature service): Delete features from an online feature service.
- Display a WFS layer: Display a layer from a WFS service, requesting only features for the current extent.
- Display annotation: Display annotation from a feature service URL.
- Display clusters: Display a web map with a point feature layer that has feature reduction enabled to aggregate points into clusters.
- Display feature layers: Display feature layers from various data sources.
- Display layer view draw state: Determine if a layer is currently being viewed.
- Display OGC API Feature Collection: This sample demonstrates how to display an OGC API feature collection and query features while navigating the map view.
- Display overview map: Include an overview or inset map as an additional map view to show the wider context of the primary view.
- Display utility associations: Create graphics for utility associations in a utility network.
- Edit and sync features: Synchronize offline edits with a feature service.
- Edit feature attachments: Add, delete, and download attachments for features from a service.
- Edit features with feature-linked annotation: Edit feature attributes which are linked to annotation through an expression.
- Edit with branch versioning: Create, query and edit a specific server version using service geodatabase.
- Feature collection layer (query): Create a feature collection layer to show a query result from a service feature table.
- Feature layer (dictionary renderer): Convert features into graphics to show them with mil2525d symbols.
- Feature layer change renderer: Change the appearance of a feature layer with a renderer.
- Feature layer extrusion: Extrude features based on their attributes.
- Feature layer query: Find features in a feature table which match an SQL query.
- Feature layer rendering mode (map): Render features statically or dynamically by setting the feature layer rendering mode.
- Feature layer rendering mode (scene): Render features in a scene statically or dynamically by setting the feature layer rendering mode.
- Feature layer selection: Select features in a feature layer.
- Filter by definition expression or display filter: Filter features displayed on a map using a definition expression or a display filter.
- Load WFS with XML query: Load a WFS feature table using an XML query.
- Local Server feature layer: Start a local feature service and display its features in a map.
- Map reference scale: Set the map's reference scale and which feature layers should honor the reference scale.
- Perform valve isolation trace: Run a filtered trace to locate operable features that will isolate an area from the flow of network resources.
- Query map image sublayer: Find features in a sublayer based on attributes and location.
- Service feature table (cache): Display a feature layer from a service using the **on interaction cache** feature request mode.
- Service feature table (manual cache): Display a feature layer from a service using the **manual cache** feature request mode.
- Service feature table (no cache): Display a feature layer from a service using the **no cache** feature request mode.
- Show labels on layer in 3D: This sample demonstrates how to display custom labels in a 3D scene.
- Show labels on layers: Display custom labels on a feature layer.
- Snap geometry edits: Use the Geometry Editor to edit a geometry and align it to existing geometries on a map.
- Symbolize a shapefile: Display a shapefile with custom symbology.
- Trace utility network: Discover connected features in a utility network using connected, subnetwork, upstream, and downstream traces.
- Unique value renderer: Render features in a layer using a distinct symbol for each unique attribute value.
- Update attributes (feature service): Update feature attributes in an online feature service.
- Update geometry (feature service): Update a feature's location in an online feature service.
See also Layer.
Member Function Documentation
[explicit]
FeatureLayer::FeatureLayer (Esri::ArcGISRuntime::FeatureTable *featureTable , QObject *parent = nullptr)
Initialize the layer with the given featureTable and optional parent.
- featureTable - The feature table used as the data source of the feature layer.
- parent - The optional parent QObject.
Any inherited FeatureTable type can be used as the input parameter for this constructor, except FeatureCollectionTable. To display features in a FeatureCollectionTable, use FeatureCollectionLayer.
Note: You cannot create a FeatureLayer from a FeatureCollectionTable.
[since Esri::ArcGISRuntime 100.3]
FeatureLayer::FeatureLayer (Esri::ArcGISRuntime::Item *item, qint64 serviceLayerId , QObject *parent = nullptr)
Creates a new feature layer object from a feature service portal item.
- item - A feature service PortalItem. The item's type must be PortalItemType::FeatureService.
- serviceLayerId - The layer id of an individual layer in the ArcGIS feature service represented by the item parameter.
- parent - The optional parent QObject.
The feature layer will fail to load if an invalid portal item is passed in.
This function was introduced in Esri::ArcGISRuntime 100.3.
See also Layer::item.
[explicit, since Esri::ArcGISRuntime 100.14]
FeatureLayer::FeatureLayer (Esri::ArcGISRuntime::Item *item, QObject *parent = nullptr)
Creates a new feature layer object from a feature layer portal item or feature service portal item.
- item - A feature layer or feature service PortalItem.
- parent - The optional parent QObject.
If the portal item is a feature service, then the FeatureLayer is created from the first layer on the service.
This function was introduced in Esri::ArcGISRuntime 100.14.
See also Layer::item.
[override virtual]
FeatureLayer::~FeatureLayer ()
Destructor.
void FeatureLayer::clearSelection ()
Clears selection on all features.
QString FeatureLayer::definitionExpression () const
Returns a SQL expression that limits the features available for query and display on the feature layer.
The definition expression string should follow standard SQL syntax as detailed in the SQL reference for query expressions used in ArcGIS document.
See also setDefinitionExpression().
[since Esri::ArcGISRuntime 100.13]
Esri::ArcGISRuntime::DisplayFilterDefinition *FeatureLayer::displayFilterDefinition () const
Returns how features are filtered from the display.
Use this property to reduce the number of features displayed in the map or scene view. The filter aims to improve data visualization and optimize rendering performance. It only affects the display of features so all features are still available for query methods such as selectFeaturesAsync(const Esri::ArcGISRuntime::QueryParameters&, Esri::ArcGISRuntime::SelectionMode, QObject*): Future<FeatureQueryResult>.
This function was introduced in Esri::ArcGISRuntime 100.13.
See also setDisplayFilterDefinition(), ManualDisplayFilterDefinition, and ScaleDisplayFilterDefinition.
[since Esri::ArcGISRuntime 200.2]
Esri::ArcGISRuntime::FeatureReduction *FeatureLayer::featureReduction () const
Defines properties for dynamically aggregating and summarizing groups of features as the map scale or visible extent changes.
FeatureReduction is only supported for point feature layers in dynamic rendering mode (FeatureRenderingMode::Dynamic) in 2D.
The following conditions will generate a LayerViewState error and will result in the layer rendering the original features. 1. A FeatureLayer that uses static rendering mode is enabled with FeatureReduction. 2. A FeatureLayer enabled with FeatureReduction is added to a Scene (or a Scene that contains such a layer is loaded). 3. An unsupported renderer is used as the AggregationFeatureReduction::renderer. See AggregationFeatureReduction::renderer for more info.
If this property is explicitly set to nullptr
, FeatureReduction is removed from the FeatureLayer and is not persisted when saving the map.
This function was introduced in Esri::ArcGISRuntime 200.2.
See also setFeatureReduction().
Esri::ArcGISRuntime::FeatureTable *FeatureLayer::featureTable () const
Returns the feature table whose features are drawn on the map by this layer.
[override virtual, since Esri::ArcGISRuntime 100.12]
Esri::ArcGISRuntime::LayerFloorDefinition *FeatureLayer::floorDefinition () const
Reimplements: FloorAware::floorDefinition() const.
Defines the properties that allow a layer to be floor-aware.
When a layer is configured as floor-aware, it has a floorDefinition property that defines properties that allow a layer to be floor-aware. When it is nullptr
(default value) the specific layer does not support floor filtering.
This function was introduced in Esri::ArcGISRuntime 100.12.
See also setFloorDefinition().
[override virtual, since Esri::ArcGISRuntime 100.3]
Esri::ArcGISRuntime::TimeExtent FeatureLayer::fullTimeExtent () const
Reimplements: TimeAware::fullTimeExtent() const.
Returns the full time extent of the layer.
If the layer, such as an ArcGISMapImageLayer, has sublayers with different time extents, fullTimeExtent is a union of its sublayer's time extents.
This function was introduced in Esri::ArcGISRuntime 100.3.
[signal]
void FeatureLayer::fullTimeExtentChanged ()
Signal emitted when the fullTimeExtent changes.
See also TimeAware.
bool FeatureLayer::isLabelsEnabled () const
Returns true
if features in the layer are labelled, otherwise false
.
[override virtual]
bool FeatureLayer::isPopupEnabled () const
Reimplements: PopupSource::isPopupEnabled() const.
Returns whether the Popup is enabled on the PopupSource.
[since Esri::ArcGISRuntime 100.5]
bool FeatureLayer::isScaleSymbols () const
Returns true
if the layer's symbols and labels honor the map's reference scale, otherwise false
.
If the map has a positive reference scale, and the layer honors it, then symbols and labels are drawn at their specified size when the viewing scale is the same as the reference scale. They will grow or shrink as the view zooms in or out, to keep the symbol a fixed size on the map. If the map has no reference scale, the reference scale is zero, or this feature layer's scaleSymbols property is false
, then the symbols and labels will be drawn at their fixed screen size.
The default value is false
.
This function was introduced in Esri::ArcGISRuntime 100.5.
[override virtual, since Esri::ArcGISRuntime 100.3]
bool FeatureLayer::isSupportsTimeFiltering () const
Reimplements: TimeAware::isSupportsTimeFiltering() const.
Returns true
if the layer supports filtering data based on its time values, false
otherwise.
This function was introduced in Esri::ArcGISRuntime 100.3.
[override virtual, since Esri::ArcGISRuntime 100.3]
bool FeatureLayer::isTimeFilteringEnabled () const
Reimplements: TimeAware::isTimeFilteringEnabled() const.
Returns true
if the layer filters data based on its GeoView::timeExtent, false
otherwise.
This is only applicable if the layer's isSupportsTimeFiltering value is true
. If the GeoView::timeExtent value is empty, no time filtering is applied and all content is rendered.
This function was introduced in Esri::ArcGISRuntime 100.3.
[since Esri::ArcGISRuntime 100.1]
Esri::ArcGISRuntime::LabelDefinitionListModel *FeatureLayer::labelDefinitions () const
Returns the collection of LabelDefinition objects that define how labels are displayed.
This function was introduced in Esri::ArcGISRuntime 100.1.
[override virtual]
Esri::ArcGISRuntime::PopupDefinition *FeatureLayer::popupDefinition () const
Reimplements: PopupSource::popupDefinition() const.
See PopupSource.
See also setPopupDefinition().
[since Esri::ArcGISRuntime 100.1]
quint64 FeatureLayer::refreshInterval () const
Returns the refresh interval used by the layer, in milliseconds.
Layers request features from the service each time this interval elapses
A value of 0 means to never refresh.
This function was introduced in Esri::ArcGISRuntime 100.1.
See also setRefreshInterval().
Esri::ArcGISRuntime::Renderer *FeatureLayer::renderer() const
Returns the renderer specifying how the features are symbolized.
See also setRenderer().
[since Esri::ArcGISRuntime 100.2]
Esri::ArcGISRuntime::FeatureRenderingMode FeatureLayer::renderingMode () const
Returns the mode that defines how the feature layer is rendered.
FeatureRenderingMode::Static mode is better suited for displaying large datasets (in terms of the number of vertices) and for complex symbology because it does not update the layer's display while pan/zoom operations are in progress.
FeatureRenderingMode::Dynamic mode is better suited for small datasets that update frequently or for better interactive experiences when the layer's display is updated continuously while pan/zoom operations are in progress.
This function was introduced in Esri::ArcGISRuntime 100.2.
See also setRenderingMode().
void FeatureLayer::resetFeaturesVisible ()
Resets the visibility of all features back to their original state.
void FeatureLayer::resetRenderer ()
Resets the renderer back to the original renderer provided by the FeatureTable.
[since Esri::ArcGISRuntime 100.2]
Esri::ArcGISRuntime::LayerSceneProperties FeatureLayer::sceneProperties () const
Returns the properties that are applied when the layer is rendered in a 3D scene using a SceneView object.
These settings will have no effect if the layer is displayed in a MapView.
This function was introduced in Esri::ArcGISRuntime 100.2.
See also setSceneProperties().
void FeatureLayer::selectFeature (Esri::ArcGISRuntime::Feature *feature)
Selects the given feature and adds it to the current collection of selected features.
- feature - The feature.
Selected features are rendered according to the GeoView::selectionProperties.
void FeatureLayer::selectFeatures (const QList<Esri::ArcGISRuntime::Feature *> &features)
Selects the given features and adds them to the current collection of selected features.
- features - A collection of features to be selected.
Use the selectedFeatures: Future<FeatureQueryResult> to retrieve all of the selected features.
[since Esri::ArcGISRuntime 200.2]
QFuture<Esri::ArcGISRuntime::FeatureQueryResult *> FeatureLayer::selectFeaturesAsync (const Esri::ArcGISRuntime::QueryParameters ¶meters, Esri::ArcGISRuntime::SelectionMode mode, QObject *parent = nullptr)
Selects the features that match the criteria in the QueryParameters object and adds them to the current collection of selected features.
- parameters - A query that defines features to select from the FeatureTable.
- mode - Defines how the collection of currently selected features will be updated with the features returned from the query.
- parent - The optional parent QObject
This method returns a QFuture for the asynchronous operation. Use future.then() to continue processing when the operation completes. Use future.onFailed() to handle exceptions of type ErrorException.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.2.
[since Esri::ArcGISRuntime 200.2]
QFuture<Esri::ArcGISRuntime::FeatureQueryResult *> FeatureLayer::selectedFeaturesAsync (QObject *parent = nullptr)
A collection of the currently selected features.
- parent - The optional parent QObject
This method returns a QFuture for the asynchronous operation. Use future.then() to continue processing when the operation completes. Use future.onFailed() to handle exceptions of type ErrorException.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.2.
[since Esri::ArcGISRuntime 100.3]
qint64 FeatureLayer::serviceLayerId () const
Returns the service layer ID in the feature service that this layer was created from.
This function was introduced in Esri::ArcGISRuntime 100.3.
void FeatureLayer::setDefinitionExpression (const QString &expression)
Sets the definitionExpression to an expression.
The definition expression string uses the SQL-92 WHERE clause syntax. Be sure to escape special characters in the expression string as required for your platform. The DATE
keyword expects the date format yyyy-mm-dd
and the TIMESTAMP
keyword expects the time stamp format yyyy-mm-dd
hh:mm:ss. See the ArcGIS Blog article Querying Feature Services Date-Time Queries for more information.
See also definitionExpression.
[since Esri::ArcGISRuntime 100.13]
void FeatureLayer::setDisplayFilterDefinition (Esri::ArcGISRuntime::DisplayFilterDefinition *displayFilterDefinition )
Sets the displayFilterDefinition to displayFilterDefinition.
This function was introduced in Esri::ArcGISRuntime 100.13.
See also displayFilterDefinition.
[since Esri::ArcGISRuntime 200.3]
void FeatureLayer::setFeatureReduction (Esri::ArcGISRuntime::FeatureReduction *featureReduction )
Sets the featureReduction to featureReduction.
This function was introduced in Esri::ArcGISRuntime 200.3.
See also featureReduction.
void FeatureLayer::setFeatureVisible (Esri::ArcGISRuntime::Feature *feature, bool visible)
Sets the visibility of the given feature.
- feature - The feature.
- visible -
true
to show the features, otherwisefalse
.
void FeatureLayer::setFeaturesVisible (const QList<Esri::ArcGISRuntime::Feature *> &features, bool visible)
Sets the visibility of the given list of features.
[override virtual]
void FeatureLayer::setFloorDefinition (Esri::ArcGISRuntime::LayerFloorDefinition *floorDefinition )
Sets the floorDefinition to floorDefinition.
See also floorDefinition.
void FeatureLayer::setLabelsEnabled (bool enabled)
Sets whether labels are enabled on features in layer.
See also isLabelsEnabled().
[override virtual]
void FeatureLayer::setPopupDefinition (Esri::ArcGISRuntime::PopupDefinition *popupDefinition )
Reimplements: PopupSource::setPopupDefinition(Esri::ArcGISRuntime::PopupDefinition *popupDefinition).
Sets the popup definition to popupDefinition.
See also popupDefinition() and PopupSource.
[override virtual]
void FeatureLayer::setPopupEnabled (bool popupEnabled )
Reimplements: PopupSource::setPopupEnabled(bool popupEnabled).
Sets whether the PopupSource is enabled to popupEnabled.
See also isPopupEnabled() and PopupSource.
[since Esri::ArcGISRuntime 100.1]
void FeatureLayer::setRefreshInterval (quint64 milliseconds)
Sets the refresh interval used by the layer to milliseconds.
Layers request features from the service each time this interval elapses
A value of 0 means to never refresh.
This function was introduced in Esri::ArcGISRuntime 100.1.
See also refreshInterval().
void FeatureLayer::setRenderer (Esri::ArcGISRuntime::Renderer *renderer)
Sets the renderer specifying how the features should be symbolized.
See also renderer().
[since Esri::ArcGISRuntime 100.2]
void FeatureLayer::setRenderingMode (Esri::ArcGISRuntime::FeatureRenderingMode renderingMode )
Sets the rendering mode of the feature layer to renderingMode.
This function was introduced in Esri::ArcGISRuntime 100.2.
See also renderingMode().
[since Esri::ArcGISRuntime 100.5]
void FeatureLayer::setScaleSymbols (bool scaleSymbols )
Sets whether the sublayer renders its symbols based on scale to scaleSymbols.
A value of false
means the symbols stay the same size in screen units regardless of the map scale.
The default value is false
.
This function was introduced in Esri::ArcGISRuntime 100.5.
See also isScaleSymbols().
[since Esri::ArcGISRuntime 100.2]
void FeatureLayer::setSceneProperties (const Esri::ArcGISRuntime::LayerSceneProperties &sceneProperties )
Sets layer scene properties to sceneProperties, which can be used to make changes to how features are displayed in a SceneView.
This function was introduced in Esri::ArcGISRuntime 100.2.
See also sceneProperties().
[since Esri::ArcGISRuntime 100.10]
void FeatureLayer::setTilingMode (Esri::ArcGISRuntime::FeatureTilingMode tilingMode )
Sets the tilingMode to tilingMode.
This function was introduced in Esri::ArcGISRuntime 100.10.
See also tilingMode.
[override virtual, since Esri::ArcGISRuntime 100.3]
void FeatureLayer::setTimeFilteringEnabled (bool timeFilteringEnabled )
Reimplements: TimeAware::setTimeFilteringEnabled(bool timeFilteringEnabled).
Sets whether the layer uses the time range defined on the geo view to timeFilteringEnabled.
This function was introduced in Esri::ArcGISRuntime 100.3.
See also isTimeFilteringEnabled().
[override virtual, since Esri::ArcGISRuntime 100.3]
void FeatureLayer::setTimeOffset (const Esri::ArcGISRuntime::TimeValue &timeOffset )
Reimplements: TimeAware::setTimeOffset(const Esri::ArcGISRuntime::TimeValue &timeOffset).
Sets the time offset of the layer to timeOffset.
The time offset is subtracted from the time extent set on the layer's geo view. This can be used to overlay data from different periods of time for comparison.
This function was introduced in Esri::ArcGISRuntime 100.3.
See also timeOffset().
[since Esri::ArcGISRuntime 100.10]
Esri::ArcGISRuntime::FeatureTilingMode FeatureLayer::tilingMode () const
Returns the mode defines whether feature tiling is used to retrieve the features from the feature service.
The default tiling mode is FeatureTilingMode::EnabledWhenSupported.
Changes how feature tiling is handled by the feature layer.
This function was introduced in Esri::ArcGISRuntime 100.10.
See also setTilingMode().
[override virtual, since Esri::ArcGISRuntime 100.3]
Esri::ArcGISRuntime::TimeValue FeatureLayer::timeInterval () const
Reimplements: TimeAware::timeInterval() const.
Returns the suggested time slider step size for this time aware layer.
You can use this information to set the step size for a time slider control. The value is empty if no time interval is suggested. The author of the layer's data typically configures this property if the data has been collected on a regular basis. For example, the daily position of a hurricane.
This function was introduced in Esri::ArcGISRuntime 100.3.
[override virtual, since Esri::ArcGISRuntime 100.3]
Esri::ArcGISRuntime::TimeValue FeatureLayer::timeOffset () const
Reimplements: TimeAware::timeOffset() const.
Returns the amount of time by which the temporal values of this layer's data points are offset when displaying it in a GeoView.
The time offset is subtracted from the time extent set on the layer's GeoView. This is useful if you want to overlay data in multiple layers that lies within different temporal extents. For example, if you want to compare data in one layer for a certain year with data in the same layer from the subsequent year, you can create two layers that reference the same data's service endpoint but set the TimeValue in one of the layers to be one year.
This function was introduced in Esri::ArcGISRuntime 100.3.
See also setTimeOffset().
[since Esri::ArcGISRuntime 100.7]
QJsonObject FeatureLayer::unknownJson () const
Returns the unknown JSON data from the source JSON.
Unknown JSON is a QJsonObject of values not defined in the ArcGIS specification used to create this object but found in the source JSON. If the object is written back to JSON, any unknown JSON data is not persisted. The ArcGIS specification may be for a web map, web scene, REST API, and so on.
This function was introduced in Esri::ArcGISRuntime 100.7.
void FeatureLayer::unselectFeature (Esri::ArcGISRuntime::Feature *feature)
Unselects the given feature and removes it from the current collection of selected features.
- feature - The feature.
void FeatureLayer::unselectFeatures (const QList<Esri::ArcGISRuntime::Feature *> &features)
Unselects the given features and removes them from the current collection of selected features.
[since Esri::ArcGISRuntime 100.7]
QJsonObject FeatureLayer::unsupportedJson () const
Returns the unsupported JSON data from the source JSON.
Unsupported JSON is a QJsonObject of values defined in the ArcGIS specification used to create this object but not currently used in this API. If the object is written back to JSON, any unsupported JSON data is persisted. The ArcGIS specification may be from a web map, web scene, REST API, and so on.
This function was introduced in Esri::ArcGISRuntime 100.7.