LocationDistanceMeasurement Class

  • LocationDistanceMeasurement
  • class Esri::ArcGISRuntime::LocationDistanceMeasurement

    An analysis object that evaluates direct, vertical, and horizontal distances between two points defined by start and end point locations. More...

    Header: #include <LocationDistanceMeasurement.h>
    Since: Esri::ArcGISRuntime 100.3
    Inherits: Esri::ArcGISRuntime::Analysis

    This class was introduced in Esri::ArcGISRuntime 100.3.

    Public Functions

    LocationDistanceMeasurement(const Esri::ArcGISRuntime::Point &startLocation, const Esri::ArcGISRuntime::Point &endLocation, QObject *parent = nullptr)
    virtual ~LocationDistanceMeasurement() override
    Esri::ArcGISRuntime::Distance directDistance() const
    Esri::ArcGISRuntime::Point endLocation() const
    Esri::ArcGISRuntime::Distance horizontalDistance() const
    void setEndLocation(const Esri::ArcGISRuntime::Point &endLocation)
    void setStartLocation(const Esri::ArcGISRuntime::Point &startLocation)
    void setUnitSystem(Esri::ArcGISRuntime::UnitSystem unitSystem)
    Esri::ArcGISRuntime::Point startLocation() const
    Esri::ArcGISRuntime::UnitSystem unitSystem() const
    Esri::ArcGISRuntime::Distance verticalDistance() const

    Signals

    void measurementChanged(const Esri::ArcGISRuntime::Distance &directDistance, const Esri::ArcGISRuntime::Distance &horizontalDistance, const Esri::ArcGISRuntime::Distance &verticalDistance)

    Detailed Description

    The LocationDistanceMeasurement analysis measures the distance between a start and an end location (each using Point geometry).

    Three distance components are calculated:

    • direct distance - the direct distance between the start and end location
    • horizontal distance - the horizontal component of the direct distance
    • vertical distance - the vertical component of the direct distance

    See also Distance.

    Member Function Documentation

    LocationDistanceMeasurement::LocationDistanceMeasurement(const Esri::ArcGISRuntime::Point &startLocation, const Esri::ArcGISRuntime::Point &endLocation, QObject *parent = nullptr)

    Creates a LocationDistanceMeasurement analysis object that defines a start and an end location using Point objects.

    The LocationDistanceMeasurement analysis result is a distance measurement between the start and end locations with direct, horizontal, and vertical components.

    • startLocation - A point that defines the start location of the measurement.
    • endLocation - A point that defines the end location of the measurement.
    • parent - An optional parent.

    [signal] void LocationDistanceMeasurement::measurementChanged(const Esri::ArcGISRuntime::Distance &directDistance, const Esri::ArcGISRuntime::Distance &horizontalDistance, const Esri::ArcGISRuntime::Distance &verticalDistance)

    Signal emitted when any distance calculation component in a LocationDistanceMeasurement analysis has changed.

    • directDistance - The new direct distance calculation.
    • horizontalDistance - The new horizontal distance calculation.
    • verticalDistance - The new vertical distance calculation.

    See also Distance.

    [override virtual] LocationDistanceMeasurement::~LocationDistanceMeasurement()

    Destructor.

    Esri::ArcGISRuntime::Distance LocationDistanceMeasurement::directDistance() const

    Returns the direct distance component of the LocationDistanceMeasurement.

    The distance's unit will be in the chosen UnitSystem and appropriate for the scale. The value will be empty until the analysis is added to the analysis overlay of a scene view.

    See also measurementChanged.

    Esri::ArcGISRuntime::Point LocationDistanceMeasurement::endLocation() const

    Returns the end location of the LocationDistanceMeasurement.

    The point coordinates (x,y,z) define the end location in 3D space.

    See also setEndLocation().

    Esri::ArcGISRuntime::Distance LocationDistanceMeasurement::horizontalDistance() const

    Returns the horizontal distance component of the LocationDistanceMeasurement.

    The distance's unit will be in the chosen UnitSystem and appropriate for the scale. The value will be empty until the analysis is added to the analysis overlay of a scene view.

    See also measurementChanged.

    void LocationDistanceMeasurement::setEndLocation(const Esri::ArcGISRuntime::Point &endLocation)

    Sets the end location of the LocationDistanceMeasurement to endLocation.

    The point coordinates (x,y,z) define the end location in 3D space.

    See also endLocation().

    void LocationDistanceMeasurement::setStartLocation(const Esri::ArcGISRuntime::Point &startLocation)

    Sets the start location of the LocationDistanceMeasurement to startLocation.

    The point coordinates (x,y,z) define the start location in 3D space.

    See also startLocation().

    void LocationDistanceMeasurement::setUnitSystem(Esri::ArcGISRuntime::UnitSystem unitSystem)

    Sets the UnitSystem of the LocationDistanceMeasurement under which distances are calculated to unitSystem.

    See also unitSystem().

    Esri::ArcGISRuntime::Point LocationDistanceMeasurement::startLocation() const

    Returns the start location of the LocationDistanceMeasurement.

    The point coordinates (x,y,z) define the start location in 3D space.

    See also setStartLocation().

    Esri::ArcGISRuntime::UnitSystem LocationDistanceMeasurement::unitSystem() const

    Returns the UnitSystem of the LocationDistanceMeasurement under which distances are calculated.

    See also setUnitSystem().

    Esri::ArcGISRuntime::Distance LocationDistanceMeasurement::verticalDistance() const

    Returns the vertical distance component of the LocationDistanceMeasurement.

    The distance's unit will be in the chosen UnitSystem and appropriate for the scale. The value will be empty until the analysis is added to the analysis overlay of a scene view.

    See also measurementChanged.

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