Skip To Content ArcGIS for Developers Sign In Dashboard

LineSegment Class

(Esri::ArcGISRuntime::LineSegment)

Represents a straight line between a start and end point. More...

Header: #include <LineSegment>
Since: Esri::ArcGISRuntime 100.0
Inherits: Segment

Public Functions

LineSegment()
LineSegment(const Point &startPoint, const Point &endPoint)
LineSegment(const Point &startPoint, const Point &endPoint, const SpatialReference &spatialReference)
LineSegment(double xStart, double yStart, double xEnd, double yEnd)
LineSegment(double xStart, double yStart, double xEnd, double yEnd, const SpatialReference &spatialReference)
LineSegment(double xStart, double yStart, double zStart, double xEnd, double yEnd, double zEnd)
LineSegment(double xStart, double yStart, double zStart, double xEnd, double yEnd, double zEnd, const SpatialReference &spatialReference)
LineSegment(const LineSegment &other)
LineSegment(LineSegment &&other)
~LineSegment()
LineSegment &operator=(const LineSegment &other)
LineSegment &operator=(LineSegment &&other)

Static Public Members

LineSegment createLineAtAngleFromStartPoint(const Point &startPoint, double angleRadians, double length)

Detailed Description

Represents a straight line between a start and end point.

LineSegments are used to represent the edges of Polygons and Polylines.

The SpatialReference of a LineSegment will be unset if one is not set in its constructor. If subsequently added to a Part, it will take on the SpatialReference of that SegmentCollection.

LineSegment is immutable. Create new instances by using the constructors and factory methods, instead of changing the properties of an existing LineSegment.

Member Function Documentation

LineSegment::LineSegment()

Default constructor.

A default constructed LineSegment should not be used. This constructor is provided for convenience only.

LineSegment::LineSegment(const Point &startPoint, const Point &endPoint)

Constructor that takes a startPoint and an endPoint.

LineSegment::LineSegment(const Point &startPoint, const Point &endPoint, const SpatialReference &spatialReference)

Constructor that takes a startPoint, endPoint and spatialReference.

LineSegment::LineSegment(double xStart, double yStart, double xEnd, double yEnd)

Constructor that takes an xStart, yStart, xEnd, and yEnd.

LineSegment::LineSegment(double xStart, double yStart, double xEnd, double yEnd, const SpatialReference &spatialReference)

Constructor that takes an xStart, yStart, xEnd, yEnd and spatialReference.

LineSegment::LineSegment(double xStart, double yStart, double zStart, double xEnd, double yEnd, double zEnd)

Constructor that takes an xStart, yStart, zStart, xEnd, yEnd and zEnd.

LineSegment::LineSegment(double xStart, double yStart, double zStart, double xEnd, double yEnd, double zEnd, const SpatialReference &spatialReference)

Constructor that takes an xStart, yStart, zStart, xEnd, yEnd, zEnd and spatialReference.

LineSegment::LineSegment(const LineSegment &other)

Copy constructor from other LineSegment.

LineSegment::LineSegment(LineSegment &&other)

Move constructor from other LineSegment.

LineSegment::~LineSegment()

Destructor.

[static] LineSegment LineSegment::createLineAtAngleFromStartPoint(const Point &startPoint, double angleRadians, double length)

Factory method to create a LineSegment from a startPoint, angleRadians, and a length.

LineSegment &LineSegment::operator=(const LineSegment &other)

Assignment operator from other LineSegment.

LineSegment &LineSegment::operator=(LineSegment &&other)

Move operator from other LineSegment.


Feedback on this topic?