ClosestFacilityParameters Class

  • ClosestFacilityParameters
  • class Esri::ArcGISRuntime::ClosestFacilityParameters

    Parameters for a ClosestFacilityTask, such as facilities, incidents, barriers, and whether to return directions. More...

    Header: #include <ClosestFacilityParameters.h>
    Since: Esri::ArcGISRuntime 100.1

    This class was introduced in Esri::ArcGISRuntime 100.1.

    Public Functions

    ClosestFacilityParameters(Esri::ArcGISRuntime::ClosestFacilityParameters &&other)
    ClosestFacilityParameters(const Esri::ArcGISRuntime::ClosestFacilityParameters &other)
    ClosestFacilityParameters()
    Esri::ArcGISRuntime::ClosestFacilityParameters &operator=(Esri::ArcGISRuntime::ClosestFacilityParameters &&other)
    Esri::ArcGISRuntime::ClosestFacilityParameters &operator=(const Esri::ArcGISRuntime::ClosestFacilityParameters &other)
    ~ClosestFacilityParameters()
    QStringList accumulateAttributeNames() const
    void clearFacilities()
    void clearIncidents()
    void clearPointBarriers()
    void clearPolygonBarriers()
    void clearPolylineBarriers()
    double defaultImpedanceCutoff() const
    int defaultTargetFacilityCount() const
    Esri::ArcGISRuntime::UnitSystem directionsDistanceUnits() const
    QString directionsLanguage() const
    Esri::ArcGISRuntime::DirectionsStyle directionsStyle() const
    bool isEmpty() const
    bool isReturnDirections() const
    bool isReturnPointBarriers() const
    bool isReturnPolygonBarriers() const
    bool isReturnPolylineBarriers() const
    bool isReturnRoutes() const
    Esri::ArcGISRuntime::SpatialReference outputSpatialReference() const
    Esri::ArcGISRuntime::RouteShapeType routeShapeType() const
    QString searchWhereClause(const QString &sourceName) const
    void setAccumulateAttributeNames(const QStringList &accumulateAttributeNames)
    void setDefaultImpedanceCutoff(double defaultImpedanceCutoff)
    void setDefaultTargetFacilityCount(int defaultTargetFacilityCount)
    void setDirectionsDistanceUnits(Esri::ArcGISRuntime::UnitSystem directionsDistanceUnits)
    void setDirectionsLanguage(const QString &directionsLanguage)
    void setDirectionsStyle(Esri::ArcGISRuntime::DirectionsStyle directionsStyle)
    void setFacilities(const QList<Esri::ArcGISRuntime::Facility> &facilities)
    void setFacilitiesWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)
    void setIncidents(const QList<Esri::ArcGISRuntime::Incident> &incidents)
    void setIncidentsWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)
    void setOutputSpatialReference(const Esri::ArcGISRuntime::SpatialReference &outputSpatialReference)
    void setPointBarriers(const QList<Esri::ArcGISRuntime::PointBarrier> &pointBarriers)
    void setPointBarriersWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)
    void setPolygonBarriers(const QList<Esri::ArcGISRuntime::PolygonBarrier> &polygonBarriers)
    void setPolygonBarriersWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)
    void setPolylineBarriers(const QList<Esri::ArcGISRuntime::PolylineBarrier> &polylineBarriers)
    void setPolylineBarriersWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)
    void setReturnDirections(bool returnDirections)
    void setReturnPointBarriers(bool returnPointBarriers)
    void setReturnPolygonBarriers(bool returnPolygonBarriers)
    void setReturnPolylineBarriers(bool returnPolylineBarriers)
    void setReturnRoutes(bool returnRoutes)
    void setRouteShapeType(Esri::ArcGISRuntime::RouteShapeType routeShapeType)
    void setSearchWhereClause(const QString &sourceName, const QString &searchWhereClause)
    void setStartTime(const QDateTime &startTime)
    void setStartTimeUsage(Esri::ArcGISRuntime::StartTimeUsage startTimeUsage)
    void setTravelDirection(Esri::ArcGISRuntime::TravelDirection travelDirection)
    void setTravelMode(const Esri::ArcGISRuntime::TravelMode &travelMode)
    QDateTime startTime() const
    Esri::ArcGISRuntime::StartTimeUsage startTimeUsage() const
    Esri::ArcGISRuntime::TravelDirection travelDirection() const
    Esri::ArcGISRuntime::TravelMode travelMode() const

    Detailed Description

    Facilities, incidents and barriers must have the same spatial reference, but do not need to be reprojected to match the network dataset's spatial reference. For example, the network dataset could be in WKID 4326, and your map, facilities, incidents and barriers could all be in WKID 3857. The ClosestFacilityTask will automatically reproject the facilities, incidents and barriers, and output the ClosestFacilityRoute in whatever output spatial reference is specified.

    Note: ClosestFacilityParameters is only default-constructible for convenience. The standard pattern is to retrieve one from the ClosestFacilityTask class so it already contain defaults values necessary for solving closest facility.

    See also ClosestFacilityTask::createDefaultParameters.

    Member Function Documentation

    ClosestFacilityParameters::ClosestFacilityParameters(Esri::ArcGISRuntime::ClosestFacilityParameters &&other)

    Move constructor from other ClosestFacilityParameters.

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

    Copy constructor from other ClosestFacilityParameters.

    ClosestFacilityParameters::ClosestFacilityParameters()

    Default constructor.

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

    Move operator from other ClosestFacilityParameters.

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

    Assignment operator from other ClosestFacilityParameters.

    ClosestFacilityParameters::~ClosestFacilityParameters()

    Destructor.

    QStringList ClosestFacilityParameters::accumulateAttributeNames() const

    Returns the list of network attribute names to be accumulated with the analysis.

    See also setAccumulateAttributeNames().

    void ClosestFacilityParameters::clearFacilities()

    Clears facilities that were set by ClosestFacilityParameters::setFacilities().

    void ClosestFacilityParameters::clearIncidents()

    Clears incidents that were set by ClosestFacilityParameters::setIncidents().

    void ClosestFacilityParameters::clearPointBarriers()

    Clears point barriers that were set by ClosestFacilityParameters::setPointBarriers().

    void ClosestFacilityParameters::clearPolygonBarriers()

    Clears polygon barriers that were set by ClosestFacilityParameters::setPolygonBarriers().

    void ClosestFacilityParameters::clearPolylineBarriers()

    Clears polyline barriers that were set by ClosestFacilityParameters::setPolylineBarriers().

    double ClosestFacilityParameters::defaultImpedanceCutoff() const

    Returns the default impedance cutoff.

    See also setDefaultImpedanceCutoff.

    int ClosestFacilityParameters::defaultTargetFacilityCount() const

    Returns the default target facility count.

    See also setDefaultTargetFacilityCount().

    Esri::ArcGISRuntime::UnitSystem ClosestFacilityParameters::directionsDistanceUnits() const

    Returns the units in which the length information will be reported in the route directions.

    See also setDirectionsDistanceUnits().

    QString ClosestFacilityParameters::directionsLanguage() const

    Returns the language of the resulting route directions.

    See also setDirectionsLanguage().

    Esri::ArcGISRuntime::DirectionsStyle ClosestFacilityParameters::directionsStyle() const

    Returns the style of the resulting route directions.

    See also setDirectionsStyle().

    bool ClosestFacilityParameters::isEmpty() const

    Returns true if this ClosestFacilityParameters is empty.

    bool ClosestFacilityParameters::isReturnDirections() const

    Returns whether directions are returned with the ClosestFacilityResult.

    bool ClosestFacilityParameters::isReturnPointBarriers() const

    Returns whether point barriers are returned with the ClosestFacilityResult.

    bool ClosestFacilityParameters::isReturnPolygonBarriers() const

    Returns whether polygon barriers are returned with the ClosestFacilityResult.

    bool ClosestFacilityParameters::isReturnPolylineBarriers() const

    Returns whether polyline barriers are returned with the ClosestFacilityResult.

    bool ClosestFacilityParameters::isReturnRoutes() const

    Returns whether routes are returned with the ClosestFacilityResult.

    Esri::ArcGISRuntime::SpatialReference ClosestFacilityParameters::outputSpatialReference() const

    Returns the output spatial reference.

    See also setOutputSpatialReference().

    Esri::ArcGISRuntime::RouteShapeType ClosestFacilityParameters::routeShapeType() const

    Returns the output shape type for a route.

    See also setRouteShapeType().

    QString ClosestFacilityParameters::searchWhereClause(const QString &sourceName) const

    Returns the search WHERE clause from the specified sourceName.

    See also setSearchWhereClause().

    void ClosestFacilityParameters::setAccumulateAttributeNames(const QStringList &accumulateAttributeNames)

    Sets the list of network attribute names to be accumulated with the analysis to accumulateAttributeNames.

    See also accumulateAttributeNames().

    void ClosestFacilityParameters::setDefaultImpedanceCutoff(double defaultImpedanceCutoff)

    Sets the default impedance cutoff to defaultImpedanceCutoff.

    The units for impedance cutoff is based on the value of the TravelMode::impedanceAttributeName. For example, if TravelMode::impedanceAttributeName parameter is TravelTime, the defaultImpedanceCutoff is specified in minutes.

    See also defaultImpedanceCutoff().

    void ClosestFacilityParameters::setDefaultTargetFacilityCount(int defaultTargetFacilityCount)

    Sets the default target facility count to defaultTargetFacilityCount.

    See also defaultTargetFacilityCount().

    void ClosestFacilityParameters::setDirectionsDistanceUnits(Esri::ArcGISRuntime::UnitSystem directionsDistanceUnits)

    Sets the units in which the length information will be reported in the route directions to directionsDistanceUnits.

    See also directionsDistanceUnits().

    void ClosestFacilityParameters::setDirectionsLanguage(const QString &directionsLanguage)

    Sets the language of the resulting route directions to directionsLanguage.

    See also directionsLanguage().

    void ClosestFacilityParameters::setDirectionsStyle(Esri::ArcGISRuntime::DirectionsStyle directionsStyle)

    Sets the style of the resulting route directions to directionsStyle.

    See also directionsStyle().

    void ClosestFacilityParameters::setFacilities(const QList<Esri::ArcGISRuntime::Facility> &facilities)

    Sets the facilities for a ClosestFacilityTask by providing a list of Facility.

    void ClosestFacilityParameters::setFacilitiesWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)

    Sets the facilities for a ClosestFacilityTask by providing a featureTable filtered with queryParameters.

    void ClosestFacilityParameters::setIncidents(const QList<Esri::ArcGISRuntime::Incident> &incidents)

    Sets the incidents for a ClosestFacilityTask by providing a list of Incident.

    void ClosestFacilityParameters::setIncidentsWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)

    Sets the incidents for a ClosestFacilityTask by providing a featureTable filtered with queryParameters.

    void ClosestFacilityParameters::setOutputSpatialReference(const Esri::ArcGISRuntime::SpatialReference &outputSpatialReference)

    Sets the spatial reference to outputSpatialReference.

    See also outputSpatialReference().

    void ClosestFacilityParameters::setPointBarriers(const QList<Esri::ArcGISRuntime::PointBarrier> &pointBarriers)

    Sets the pointBarriers for a ClosestFacilityTask by providing a list of PointBarrier.

    void ClosestFacilityParameters::setPointBarriersWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)

    Sets the point barriers for a ClosestFacilityTask by providing a featureTable filtered with queryParameters.

    void ClosestFacilityParameters::setPolygonBarriers(const QList<Esri::ArcGISRuntime::PolygonBarrier> &polygonBarriers)

    Sets the polygonBarriers for a ClosestFacilityTask by providing a list of PolygonBarrier.

    void ClosestFacilityParameters::setPolygonBarriersWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)

    Sets the polygon barriers for a ClosestFacilityTask by providing a featureTable filtered with queryParameters.

    void ClosestFacilityParameters::setPolylineBarriers(const QList<Esri::ArcGISRuntime::PolylineBarrier> &polylineBarriers)

    Sets the polylineBarriers for a ClosestFacilityTask by providing a list of PolylineBarrier.

    void ClosestFacilityParameters::setPolylineBarriersWithFeatureTable(Esri::ArcGISRuntime::ArcGISFeatureTable *featureTable, const Esri::ArcGISRuntime::QueryParameters &queryParameters)

    Sets the polyline barriers for a ClosestFacilityTask by providing a featureTable filtered with queryParameters.

    void ClosestFacilityParameters::setReturnDirections(bool returnDirections)

    Sets whether directions are returned with the ClosestFacilityResult to returnDirections.

    See also isReturnDirections().

    void ClosestFacilityParameters::setReturnPointBarriers(bool returnPointBarriers)

    Sets whether to return PointBarriers with the ClosestFacilityResult to returnPointBarriers.

    Reusing the PointBarriers from the ClosestFacilityResult (as opposed to using the original PointBarriers) can increase the speed of any subsequent Route calculations.

    See also isReturnPointBarriers().

    void ClosestFacilityParameters::setReturnPolygonBarriers(bool returnPolygonBarriers)

    Sets whether polygon barriers are returned with the ClosestFacilityResult to returnPolygonBarriers.

    Reusing the PolygonBarriers from the ClosestFacilityResult (as opposed to using the original PolygonBarriers) can increase the speed of any subsequent Route calculations. This is particularly true for complex polygons.

    See also isReturnPolygonBarriers().

    void ClosestFacilityParameters::setReturnPolylineBarriers(bool returnPolylineBarriers)

    Sets whether polyline barriers are returned with the ClosestFacilityResult to returnPolylineBarriers.

    Reusing the PolylineBarriers from the ClosestFacilityResult (as opposed to using the original PolylineBarriers) can increase the speed of any subsequent Route calculations. This is particularly true for complex polylines.

    See also isReturnPolylineBarriers().

    void ClosestFacilityParameters::setReturnRoutes(bool returnRoutes)

    Sets whether routes are returned with the ClosestFacilityResult to returnRoutes.

    See also isReturnRoutes().

    void ClosestFacilityParameters::setRouteShapeType(Esri::ArcGISRuntime::RouteShapeType routeShapeType)

    Sets the output route shape type for a route to routeShapeType.

    See also routeShapeType().

    void ClosestFacilityParameters::setSearchWhereClause(const QString &sourceName, const QString &searchWhereClause)

    Sets the search WHERE clause from the specified sourceName to searchWhereClause.

    This filters the potential matches returned from the task based on an expression.

    Note: Search WHERE clauses are not supported for online closest facility tasks. They are only supported when solving local closest facility tasks.

    See also searchWhereClause().

    void ClosestFacilityParameters::setStartTime(const QDateTime &startTime)

    Sets the start time of the route in UTC time to startTime.

    See also startTime().

    void ClosestFacilityParameters::setStartTimeUsage(Esri::ArcGISRuntime::StartTimeUsage startTimeUsage)

    Sets the start time usage to startTimeUsage.

    See also startTimeUsage().

    void ClosestFacilityParameters::setTravelDirection(Esri::ArcGISRuntime::TravelDirection travelDirection)

    Sets the travel direction (to or away from the facility) property to travelDirection.

    See also travelDirection().

    void ClosestFacilityParameters::setTravelMode(const Esri::ArcGISRuntime::TravelMode &travelMode)

    Sets the travel mode to travelMode.

    See also travelMode().

    QDateTime ClosestFacilityParameters::startTime() const

    Returns the start time of the route in UTC time.

    See also setStartTime().

    Esri::ArcGISRuntime::StartTimeUsage ClosestFacilityParameters::startTimeUsage() const

    Returns the start time usage.

    See also setStartTimeUsage().

    Esri::ArcGISRuntime::TravelDirection ClosestFacilityParameters::travelDirection() const

    Returns the travel direction (to or away from the facility) property.

    See also setTravelDirection().

    Esri::ArcGISRuntime::TravelMode ClosestFacilityParameters::travelMode() const

    Returns the travel mode.

    See also setTravelMode().

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