Facility Class

  • Facility
  • class Esri::ArcGISRuntime::Facility

    A facility used with a closest facility task. More...

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

    This class was introduced in Esri::ArcGISRuntime 100.1.

    Public Functions

    Facility(Esri::ArcGISRuntime::Facility &&other)
    Facility(const Esri::ArcGISRuntime::Facility &other)
    Facility(const Esri::ArcGISRuntime::Point &point)
    Facility()
    Esri::ArcGISRuntime::Facility &operator=(Esri::ArcGISRuntime::Facility &&other)
    Esri::ArcGISRuntime::Facility &operator=(const Esri::ArcGISRuntime::Facility &other)
    ~Facility()
    double addedCost(const QString &attributeName) const
    Esri::ArcGISRuntime::CurbApproach curbApproach() const
    double currentBearing() const
    double currentBearingTolerance() const
    double distanceToNetworkLocation() const
    int facilityId() const
    Esri::ArcGISRuntime::Point geometry() const
    double impedanceCutoff() const
    bool isEmpty() const
    Esri::ArcGISRuntime::LocationStatus locationStatus() const
    QString name() const
    double navigationLatency() const
    double navigationSpeed() const
    Esri::ArcGISRuntime::NetworkLocation networkLocation() const
    void setAddedCost(const QString &attributeName, double costValue)
    void setCurbApproach(Esri::ArcGISRuntime::CurbApproach curbApproach)
    void setCurrentBearing(double currentBearing)
    void setCurrentBearingTolerance(double currentBearingTolerance)
    void setFacilityId(int id)
    void setGeometry(const Esri::ArcGISRuntime::Point &point)
    void setImpedanceCutoff(double impedanceCutoff)
    void setName(const QString &name)
    void setNavigationLatency(double navigationLatency)
    void setNavigationSpeed(double navigationSpeed)
    void setNetworkLocation(const Esri::ArcGISRuntime::NetworkLocation &networkLocation)

    Detailed Description

    Facilities represent locations that can serve as the starting point or ending point of a closest facility analysis, such as a fire station or a hospital. ClosestFacilityParameters contains the list of facilities. The ClosestFacilityTask creates routes between facilities and incidents.

    Member Function Documentation

    Facility::Facility(Esri::ArcGISRuntime::Facility &&other)

    Move constructor from other Facility.

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

    Copy constructor from other Facility.

    Facility::Facility(const Esri::ArcGISRuntime::Point &point)

    Constructor that takes in a point.

    Facility::Facility()

    Default constructor.

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

    Move operator from other Facility.

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

    Assignment operator from other Facility.

    Facility::~Facility()

    Destructor.

    double Facility::addedCost(const QString &attributeName) const

    Returns the added cost of a given attributeName.

    See also setAddedCost().

    Esri::ArcGISRuntime::CurbApproach Facility::curbApproach() const

    Returns the curb approach for this Facility.

    See also setCurbApproach().

    double Facility::currentBearing() const

    Returns current bearing of this Facility in degrees.

    Current bearing in degrees, measured clockwise from true north. Typical values are 0 to 360 or NaN, negative values will be subtracted from 360 (e.g. -15 => 345), values greater than 360 will be have 360 subtracted from them (e.g. 385 => 25). For this property to be used the bearing tolerance also has to be set.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also setCurrentBearing().

    double Facility::currentBearingTolerance() const

    Returns the current bearing tolerance of this Facility.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also setCurrentBearingTolerance().

    double Facility::distanceToNetworkLocation() const

    Returns the distance along the network of this Facility to a network feature in meters.

    Returns NaN if the facility has not been located.

    int Facility::facilityId() const

    Returns ID of this facility.

    This function was introduced in Esri::ArcGISRuntime 100.6.

    See also setFacilityId().

    Esri::ArcGISRuntime::Point Facility::geometry() const

    Returns the Point geometry of where this Facility is located.

    See also setGeometry().

    double Facility::impedanceCutoff() const

    Returns the Impedance Cutoff of this Facility.

    For instance, while finding the closest hospitals from the site of an accident, a cutoff value of 15 minutes would mean that the closest facility task would search for the closest hospital within 15 minutes from the incident. If the closest hospital is 17 minutes away, no routes will be returned in the output routes. A cutoff value is especially useful when searching for multiple facilities or incidents. The units for impedance cutoff is based on the value of the TravelMode::impedanceAttributeName(). For example, if TravelMode::impedanceAttributeName() is TravelTime, then impedanceCutoff is specified in minutes.

    See also setImpedanceCutoff().

    bool Facility::isEmpty() const

    Returns true if this Facility is empty.

    Esri::ArcGISRuntime::LocationStatus Facility::locationStatus() const

    Returns the LocationStatus of this Facility.

    QString Facility::name() const

    Returns the name of the Facility.

    See also setName().

    Returns the navigation latency of this Facility in seconds.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also setNavigationLatency().

    Returns the navigation speed in meters-per-second.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also setNavigationSpeed().

    Esri::ArcGISRuntime::NetworkLocation Facility::networkLocation() const

    Returns the network location of this Facility.

    See also setNetworkLocation().

    void Facility::setAddedCost(const QString &attributeName, double costValue)

    Sets the costValue for a given attributeName.

    See also addedCost().

    void Facility::setCurbApproach(Esri::ArcGISRuntime::CurbApproach curbApproach)

    Sets the curbApproach for this Facility.

    See also curbApproach().

    void Facility::setCurrentBearing(double currentBearing)

    Sets the current bearing of this Facility to currentBearing degrees.

    Bearing and bearing tolerance are meant to be used together. If you only set one, then the other is ignored.

    Bearing and bearing tolerance help to disambiguate how to locate facilities. For example, if you are driving on a freeway overpass and you need to reroute, then you would pass in your device compass bearing and a tolerance (say 45 degrees). This information is used to filter out streets that are potentially closer to your device x,y but are heading in the wrong direction (e.g. An underpass street might be closer to the x,y of your device but it is heading in the wrong direction and would be filtered out).

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also currentBearing() and setCurrentBearingTolerance.

    void Facility::setCurrentBearingTolerance(double currentBearingTolerance)

    Sets the current bearing tolerance of this Facility to currentBearingTolerance.

    Valid values are 0 to 180 or NaN.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also currentBearingTolerance() and setCurrentBearing.

    void Facility::setFacilityId(int id)

    Sets the id of this facility.

    This function was introduced in Esri::ArcGISRuntime 100.6.

    See also facilityId().

    void Facility::setGeometry(const Esri::ArcGISRuntime::Point &point)

    Sets the point geometry of where this Facility is located.

    See also geometry().

    void Facility::setImpedanceCutoff(double impedanceCutoff)

    Sets the impedanceCutoff of this Facility.

    See also impedanceCutoff().

    void Facility::setName(const QString &name)

    Sets the name of the Facility.

    See also name().

    void Facility::setNavigationLatency(double navigationLatency)

    Sets the navigation latency of this Facility to navigationLatency seconds.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also navigationLatency().

    void Facility::setNavigationSpeed(double navigationSpeed)

    Sets navigation speed of this Facility to navigationSpeed meters-per-second.

    This function was introduced in Esri::ArcGISRuntime 100.7.

    See also navigationSpeed().

    void Facility::setNetworkLocation(const Esri::ArcGISRuntime::NetworkLocation &networkLocation)

    Sets the networkLocation of this Facility.

    Set to nullptr to reset a network location.

    See also networkLocation().

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