StatisticsQueryParameters Class

FeatureTable."> StatisticsQueryParameters Class | ArcGISQtCpp
  • StatisticsQueryParameters
  • class Esri::ArcGISRuntime::StatisticsQueryParameters

    Parameters to perform a statistical query on a FeatureTable. More...

    Header: #include <StatisticsQueryParameters.h>
    Since: Esri::ArcGISRuntime 100.2

    Public Functions

    StatisticsQueryParameters()
    StatisticsQueryParameters(const QList<Esri::ArcGISRuntime::StatisticDefinition> &statisticDefinitions)
    StatisticsQueryParameters(const Esri::ArcGISRuntime::StatisticsQueryParameters &other)
    StatisticsQueryParameters(Esri::ArcGISRuntime::StatisticsQueryParameters &&other)
    ~StatisticsQueryParameters()
    void clear()
    Esri::ArcGISRuntime::Geometry geometry() const
    QStringList groupByFieldNames() const
    bool isEmpty() const
    QList<Esri::ArcGISRuntime::OrderBy> orderByFields() const
    void setGeometry(const Esri::ArcGISRuntime::Geometry &geometry)
    void setGroupByFieldNames(const QStringList &groupByFieldNames)
    void setOrderByFields(const QList<Esri::ArcGISRuntime::OrderBy> &orderByFields)
    void setSpatialRelationship(Esri::ArcGISRuntime::SpatialRelationship relationship)
    void setStatisticDefinitions(const QList<Esri::ArcGISRuntime::StatisticDefinition> &statisticDefinitions)
    void setTimeExtent(const Esri::ArcGISRuntime::TimeExtent &timeExtent)
    void setWhereClause(const QString &whereClause)
    Esri::ArcGISRuntime::SpatialRelationship spatialRelationship() const
    QList<Esri::ArcGISRuntime::StatisticDefinition> statisticDefinitions() const
    Esri::ArcGISRuntime::TimeExtent timeExtent() const
    QString whereClause() const
    Esri::ArcGISRuntime::StatisticsQueryParameters &operator=(const Esri::ArcGISRuntime::StatisticsQueryParameters &other)
    Esri::ArcGISRuntime::StatisticsQueryParameters &operator=(Esri::ArcGISRuntime::StatisticsQueryParameters &&other)

    Detailed Description

    Perform statistical analyses such as average, count, maximum, and standard deviation on a feature table by defining a StatisticType on a StatisticDefinition. Use a combination of attribute, spatial, and temporal criteria to filter the features to be analyzed. If no filters are defined, all features in the table are included in the statistical query. You can also control how to group the results.

    See also FeatureTable::queryStatisticsAsync(StatisticsQueryParameters) and StatisticDefinition::statisticType.

    Member Function Documentation

    StatisticsQueryParameters::StatisticsQueryParameters()

    Default Constructor. Create an empty StatisticsQueryParameters instance.

    [explicit] StatisticsQueryParameters::StatisticsQueryParameters(const QList<Esri::ArcGISRuntime::StatisticDefinition> &statisticDefinitions)

    Create a StatisticsQueryParameters instance with the definition of statistics (statisticDefinitions) to include in a statistical query of a table.

    StatisticsQueryParameters::StatisticsQueryParameters(const Esri::ArcGISRuntime::StatisticsQueryParameters &other)

    Copy constructor from other StatisticsQueryParameters.

    StatisticsQueryParameters::StatisticsQueryParameters(Esri::ArcGISRuntime::StatisticsQueryParameters &&other)

    Move constructor from other StatisticsQueryParameters.

    StatisticsQueryParameters::~StatisticsQueryParameters()

    Destructor

    void StatisticsQueryParameters::clear()

    Clears this StatisticsQueryParameters and sets back to empty.

    Esri::ArcGISRuntime::Geometry StatisticsQueryParameters::geometry() const

    Returns the geometry used to filter the results.

    The geometry that (along with the spatialRelationship) defines features to be included in the statistical query.

    See also setGeometry().

    QStringList StatisticsQueryParameters::groupByFieldNames() const

    Returns the fields by which statistical query results will be grouped.

    See also setGroupByFieldNames().

    bool StatisticsQueryParameters::isEmpty() const

    Returns whether this StatisticsQueryParameters is empty.

    QList<Esri::ArcGISRuntime::OrderBy> StatisticsQueryParameters::orderByFields() const

    Returns the fields by which statistical query results will be ordered.

    Results can be sorted by one or more fields. Each OrderBy instance includes a field name and whether to sort by that field in ascending or descending order. If a service-based table is being queried it must support advanced queries.

    See also setOrderByFields.

    void StatisticsQueryParameters::setGeometry(const Esri::ArcGISRuntime::Geometry &geometry)

    Sets the geometry to use as a filter.

    See also geometry().

    void StatisticsQueryParameters::setGroupByFieldNames(const QStringList &groupByFieldNames)

    Sets the fields by which statistical query results will be grouped to groupByFieldNames.

    See also groupByFieldNames().

    void StatisticsQueryParameters::setOrderByFields(const QList<Esri::ArcGISRuntime::OrderBy> &orderByFields)

    Sets the orderByFields to be applied to the query operation.

    Results can be sorted on one or more fields. Each OrderBy instance includes a field name and whether to sort by that field in ascending or descending order.

    See also orderByFields() and OrderBy.

    void StatisticsQueryParameters::setSpatialRelationship(Esri::ArcGISRuntime::SpatialRelationship relationship)

    Sets the spatial relationship to use when applying the geometry filter.

    See also spatialRelationship().

    void StatisticsQueryParameters::setStatisticDefinitions(const QList<Esri::ArcGISRuntime::StatisticDefinition> &statisticDefinitions)

    Sets the definition of statistics (input field, output name, statistic type) to include in a statistical query of a table to statisticDefinitions.

    See also statisticDefinitions().

    [since Esri::ArcGISRuntime 100.3] void StatisticsQueryParameters::setTimeExtent(const Esri::ArcGISRuntime::TimeExtent &timeExtent)

    Sets the time extent to apply in the query to timeExtent.

    This function was introduced in Esri::ArcGISRuntime 100.3.

    See also timeExtent().

    void StatisticsQueryParameters::setWhereClause(const QString &whereClause)

    Sets the SQL whereClause to apply in the query.

    See also whereClause().

    Esri::ArcGISRuntime::SpatialRelationship StatisticsQueryParameters::spatialRelationship() const

    Returns the spatial relationship that (along with the geometry) defines features to be included in the query.

    The default spatial relationship is SpatialRelationship::Intersects.

    See also setSpatialRelationship().

    QList<Esri::ArcGISRuntime::StatisticDefinition> StatisticsQueryParameters::statisticDefinitions() const

    Returns the definition of statistics (input field, output name, statistic type) to include in the statistical query of a table.

    See also setStatisticDefinitions().

    [since Esri::ArcGISRuntime 100.3] Esri::ArcGISRuntime::TimeExtent StatisticsQueryParameters::timeExtent() const

    Returns the time extent to apply in the query.

    This function was introduced in Esri::ArcGISRuntime 100.3.

    See also setTimeExtent().

    QString StatisticsQueryParameters::whereClause() const

    Returns the attribute expression that defines features to be included in the statistics query.

    The where clause should follow standard SQL syntax similar to that discussed in the document SQL reference for query expressions used in ArcGIS.

    If the where clause includes dates, they must be correctly formatted based on the geodatabase datasource used in the service. Refer to Dates and time for date formats expected by different data sources.

    ArcGISFeatureTable objects expect that any FieldType::GlobalId or FieldType::GUID parameters in the where clause are formatted as: '{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}'. All characters are uppercase, wrapped in curly braces and surrounded by single quotes.

    See also setWhereClause().

    Esri::ArcGISRuntime::StatisticsQueryParameters &StatisticsQueryParameters::operator=(const Esri::ArcGISRuntime::StatisticsQueryParameters &other)

    Assignment operator from other StatisticsQueryParameters.

    Esri::ArcGISRuntime::StatisticsQueryParameters &StatisticsQueryParameters::operator=(Esri::ArcGISRuntime::StatisticsQueryParameters &&other)

    Move operator from other StatisticsQueryParameters.

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