Namespace: GameEngine.Geometry
Class: GameEngine/Geometry/ArcGISMutablePart
Since: 1.0.0
Summary
Represents a single part of a multipart builder.
Constructors
ArcGISMutablePart(ArcGISSpatialReference)
Creates a part with a specified spatial reference.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
spatial | A spatial reference object, can be null. |
Properties
Property | Type | Nullable | Readonly | Summary |
---|---|---|---|---|
Yes | Yes | The end point of the last segment in the part. Returns null if the collection is empty. | ||
No | Yes | True if the part contains any curve segments, false otherwise. | ||
No | Yes | Indicates if the part contains no segments. | ||
No | Yes | The count of points in the part. | ||
No | Yes | The count of segments in the part. | ||
Yes | No | The spatial reference for the part. | ||
Yes | Yes | The start point of the first segment in the part. Returns null if the collection is empty. |
EndPoint
ArcGISPoint EndPoint
The end point of the last segment in the part. Returns null if the collection is empty.
HasCurves
bool HasCurves
True if the part contains any curve segments, false otherwise.
Both linear segments (represented by ArcGISLineSegment) and curve segments (represented by ArcGISCubicBezierSegment or ArcGISEllipticArcSegment) are supported in a ArcGISMutablePart. This property returns true if any curve segments (ArcGISSegment.IsCurve is true) are currently present in this part.
PointCount
ulong PointCount
The count of points in the part.
The points in the part are the start and end points of segments. Segments can share a point if the end point of one segment matches the start point of the next.
SpatialReference
ArcGISSpatialReference SpatialReference
The spatial reference for the part.
If the mutable_part does not have a spatial reference null is returned.
StartPoint
ArcGISPoint StartPoint
The start point of the first segment in the part. Returns null if the collection is empty.
Methods
Signature | Return Type | Summary |
---|---|---|
Add a new point to the end of the part by specifying the points x,y coordinates. A new line segment is added to connect the new point to the previous. | ||
Add a new point to the end of the part by specifying the points x,y,z coordinates. A new line segment is added to connect the new point to the previous. | ||
Add a new point to the end of the part. A new line segment is added to connect the new point to the previous. | ||
Add segment to the end of the part. | ||
For a segment at a specified segment_index the method returns the point index of the segment's end point. | ||
Returns a point at a specified point index. | ||
Returns all the points that are the vertexes of the part. | ||
Gets a segment at a specified segment index. | ||
Converts from a point index to a segment index that uses the given point as an end point. If the point is not an end point, then -1 is returned. | ||
Converts from a point index to a segment index of the start point and another segment index containing the end point. If the point is not a start or end point, then -1 is set. | ||
Converts from a point index to a segment index that uses the given point as a start point. If the point is not a start point, then -1 is returned. | ||
For a segment at a specified segment_index the method returns the point index of the segment's start point. | ||
Inserts a point specified by its x,y coordinates into the part at the specified point index. Line segments are added to connect the point to adjacent segments. | ||
Inserts a point specified by its x,y,z coordinate into the part at the specified point index. Line segments are added to connect the point to adjacent segments. | ||
Inserts a point into the part at the specified point index. Line segments are added to connect the point to adjacent segments. | ||
Inserts a segment into the part at the specified index. | ||
Remove all segments from the part. | ||
Removes a point from the part. Segments connecting to this point are removed and the gap filled with a new line segment. | ||
Remove a segment at the specified index from the part. | ||
Replace a point in the part at the specified point index. Segments that use this point are changed. | ||
Replaces a segment at the specified index in the part. |
AddPoint
Add a new point to the end of the part by specifying the points x,y coordinates. A new line segment is added to connect the new point to the previous.
Since 1.0.0
Arguments
Returns ulong
the point index where the point was added. If an error occurred, then -1 is returned.
AddPoint
Add a new point to the end of the part by specifying the points x,y,z coordinates. A new line segment is added to connect the new point to the previous.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
x | The x-coordinate of the new point. | |
y | The y-coordinate of the new point. | |
z | The z-coordinate of the new point. |
Returns ulong
the point index where the point was added. If an error occurred then -1 is returned.
AddPoint
ulong AddPoint(ArcGISPoint point)
Add a new point to the end of the part. A new line segment is added to connect the new point to the previous.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | The point to add. |
Returns ulong
the point index where the point was added. If an error occurred then -1 is returned.
AddSegment
ulong AddSegment(ArcGISSegment segment)
Add segment to the end of the part.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | The segment. |
Returns ulong
the segment index where the segment was added. If an error occurred, then -1 is returned.
GetEndPointIndexFromSegmentIndex
For a segment at a specified segment_index the method returns the point index of the segment's end point.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | Zero-based index of the segment. |
Returns ulong
A point index
GetPoint
ArcGISPoint GetPoint(ulong pointIndex)
Returns a point at a specified point index.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. |
Returns ArcGISPoint
A ArcGISPoint.
GetPoints
ArcGISImmutablePointCollection GetPoints()
Returns all the points that are the vertexes of the part.
Since 1.0.0
Returns ArcGISImmutablePointCollection
The immutable collections of points.
GetSegment
ArcGISSegment GetSegment(ulong segmentIndex)
Gets a segment at a specified segment index.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | Zero-based index of the segment. |
Returns ArcGISSegment
GetSegmentIndexFromEndPointIndex
Converts from a point index to a segment index that uses the given point as an end point. If the point is not an end point, then -1 is returned.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. |
Returns ulong
The segment index containing the end point or max size_t if the segment is not found.
GetSegmentIndexFromPointIndex
void GetSegmentIndexFromPointIndex(ulong pointIndex, ulong* outStartPointSegmentIndex, ulong* outEndPointSegmentIndex)
Converts from a point index to a segment index of the start point and another segment index containing the end point. If the point is not a start or end point, then -1 is set.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. | |
out | This is set to the segment index using the point as a start point. Can be null. | |
out | This is set to the segment index using the point as an end point. Can be null. |
Returns void
GetSegmentIndexFromStartPointIndex
Converts from a point index to a segment index that uses the given point as a start point. If the point is not a start point, then -1 is returned.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. |
Returns ulong
The segment index containing the start point. If point is not a start point, then -1 is returned.
GetStartPointIndexFromSegmentIndex
For a segment at a specified segment_index the method returns the point index of the segment's start point.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | Zero-based index of the segment. |
Returns ulong
A point index
InsertPoint
Inserts a point specified by its x,y coordinates into the part at the specified point index. Line segments are added to connect the point to adjacent segments.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. | |
x | The x-coordinate of the new point. | |
y | The y-coordinate of the new point. |
Returns void
InsertPoint
Inserts a point specified by its x,y,z coordinate into the part at the specified point index. Line segments are added to connect the point to adjacent segments.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. | |
x | The x-coordinate of the new point. | |
y | The y-coordinate of the new point. | |
z | The z-coordinate of the new point. |
Returns void
InsertPoint
void InsertPoint(ulong pointIndex, ArcGISPoint point)
Inserts a point into the part at the specified point index. Line segments are added to connect the point to adjacent segments.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. | |
point | The point to insert. |
Returns void
InsertSegment
void InsertSegment(ulong segmentIndex, ArcGISSegment segment)
Inserts a segment into the part at the specified index.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | Zero-based index of the segment. | |
segment | The segment to insert. |
Returns void
RemovePoint
Removes a point from the part. Segments connecting to this point are removed and the gap filled with a new line segment.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. |
Returns void
RemoveSegment
Remove a segment at the specified index from the part.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | Zero-based index of the segment. |
Returns void
SetPoint
void SetPoint(ulong pointIndex, ArcGISPoint point)
Replace a point in the part at the specified point index. Segments that use this point are changed.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
point | Zero-based index of the point. | |
point | The point. |
Returns void
SetSegment
void SetSegment(ulong segmentIndex, ArcGISSegment segment)
Replaces a segment at the specified index in the part.
Since 1.0.0
Arguments
Name | Type | Summary |
---|---|---|
segment | Zero-based index of the segment. | |
segment | The segment to be set into the collection. |