GeoprocessingFeatures Class

  • GeoprocessingFeatures
  • class Esri::ArcGISRuntime::GeoprocessingFeatures

    The geoprocessing features used as input or output parameters. More...

    Header: #include <GeoprocessingFeatures.h>
    Since: Esri::ArcGISRuntime 100.0
    Inherits: Esri::ArcGISRuntime::GeoprocessingParameter

    Public Functions

    GeoprocessingFeatures(QObject *parent = nullptr)
    GeoprocessingFeatures(const QUrl &url, QObject *parent = nullptr)
    GeoprocessingFeatures(Esri::ArcGISRuntime::FeatureSet *features, QObject *parent = nullptr)
    virtual ~GeoprocessingFeatures() override
    bool canFetchOutputFeatures() const
    Esri::ArcGISRuntime::FeatureSet *features() const
    QFuture<void> fetchOutputFeaturesAsync()
    void setFeatures(Esri::ArcGISRuntime::FeatureSet *featureSet)
    void setUrl(const QUrl &url)
    QUrl url() const

    Detailed Description

    Corresponds to GPRecordSet and GPFeatureRecordSetLayer parameter types on the service.

    A feature contains a features and may contains extra attributes on GeoElement::attributes collection. A record (or a row) doesn't contain Feature and information is stored in attributes on GeoElement::attributes collection.

    When features are returned as an output parameter, the returned results are provided as a read-only list of Feature using GeoprocessingFeatureSet. These features can be visualized on a map using temporary Graphic on a GraphicsOverlay or using FeatureCollectionTable on a FeatureCollectionLayer.

    If the geoprocessing service is configured to use a result map server, then a GeoprocessingResult::mapImageLayer is populated and it can be used to visualize the results using the symbology predefined by the service.

    When providing GeoprocessingFeatures as an input to the geoprocessing task, features can be provided directly from the FeatureQueryResult that was returned from the FeatureTable. If there is a need to create a new set a features or records, FeatureCollectionTable can be used.

    Note: A feature contains a geometry and some number of attributes. A record (or a row) is a feature that doesn't contain a geometry, only attributes.

    See also GeoprocessingFeatures, FeatureCollectionTable, and FeatureQueryResult.

    Member Function Documentation

    [explicit] GeoprocessingFeatures::GeoprocessingFeatures(QObject *parent = nullptr)

    Creates a geoprocessing features parameter.

    • parent - The optional parent QObject.

    [explicit] GeoprocessingFeatures::GeoprocessingFeatures(const QUrl &url, QObject *parent = nullptr)

    Creates a geoprocessing features parameter with a URL for the service to retrieve a feature set for input.

    • url - A URL to a feature set.
    • parent - The optional parent QObject.

    [explicit] GeoprocessingFeatures::GeoprocessingFeatures(Esri::ArcGISRuntime::FeatureSet *features, QObject *parent = nullptr)

    Creates a geoprocessing features parameter with an input FeatureSet.

    • features - An element that contains a type implementing the FeatureSet.
    • parent - The optional parent QObject.

    [override virtual] GeoprocessingFeatures::~GeoprocessingFeatures()


    bool GeoprocessingFeatures::canFetchOutputFeatures() const

    Returns whether features can be fetched from the service of an output parameter.

    This property applies to output parameters. It indicates that the parameter is an output parameter that can fetch features from the geoprocessing service. Depending on the type of the service, the features may already be available.

    If features are not present then this property indicates that you can use fetchOutputFeaturesAsync to request features, asynchronously updating the features property.

    Esri::ArcGISRuntime::FeatureSet *GeoprocessingFeatures::features() const

    Returns the features that are sent to or returned from the geoprocessing service.

    For an input parameter, this contains features to be sent to the geoprocessing service. This property will be ignored if url is set. For an output parameter, this can contain features returned from a geoprocessing service depending on the service configuration. It can be nullptr for services that have a map service, in which case calling fetchOutputFeaturesAsync will retrieve the features from the service.

    See also setFeatures().

    [since Esri::ArcGISRuntime 200.2] QFuture<void> GeoprocessingFeatures::fetchOutputFeaturesAsync()

    Starts a request to fetch output features from the service.

    If the parameter is an output of a geoprocessing service this can be used to fetch features if features is empty. It is not necessary to call this if features is already populated.

    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.

    void GeoprocessingFeatures::setFeatures(Esri::ArcGISRuntime::FeatureSet *featureSet)

    Sets the features to featureSet.

    See also features.

    void GeoprocessingFeatures::setUrl(const QUrl &url)

    Sets the url to url.

    See also url.

    QUrl GeoprocessingFeatures::url() const

    Returns the input URL that will be sent to the geoprocessing service to retrieve features.

    The URL is for input parameters only. For output parameters this is empty. For input it must be a URL that is accessible to the geoprocessing service so it can retrieve the feature set. If this property is set, it will override the features property.

    See also setUrl().

    Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.