This document is archived and information here might be outdated.  Recommended version.


IGeometryServer2.TrimExtend Method (ArcObjects .NET 10.5 SDK)
ArcObjects Library Reference (Geometry)  

IGeometryServer2.TrimExtend Method

Trims or extends each polyline in the input array using TrimExtendTo (uses IConstructCurve::ConstructExtended for extension operation).

[Visual Basic .NET]
Public Function TrimExtend ( _
    ByVal pSR As ISpatialReference, _
    ByVal pInPA As IPolylineArray, _
    ByVal pTrimExtendTo As IPolyline, _
    ByVal extendHow As Integer _
) As IPolylineArray
[C#]
public IPolylineArray TrimExtend (
    ISpatialReference pSR,
    IPolylineArray pInPA,
    IPolyline pTrimExtendTo,
    int extendHow
);
[C++]
HRESULT TrimExtend(
  ISpatialReference* pSR,
  IPolylineArray* pInPA,
  IPolyline* pTrimExtendTo,
  long extendHow,
  IPolylineArray** pTE_PA
);
[C++]

Parameters pSR
pSR is a parameter of type ISpatialReference pInPA
pInPA is a parameter of type IPolylineArray pTrimExtendTo
pTrimExtendTo is a parameter of type IPolyline extendHow extendHow is a parameter of type long pTE_PA [out, retval]
pTE_PA is a parameter of type IPolylineArray

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Remarks

Trims (cuts) polylines that intersect the trim-extend line, or extends polylines to it that don’t intersect it. See the figure below for some examples. The details of how polylines are extended can be controlled by adding together combinations of the values listed in the table below.

values to be used with the trim-extend operation

Constant

Value

Description

esriDefaultCurveExtension

0

By default, extension considers both ends of paths. The old ends remain and new points are added at the extended ends. The new points have attributes that are extrapolated from adjacent existing segments.

esriRelocateEnds

1

If an extension is performed at an end, relocate the end point to the new position instead of leaving the old point and adding a new point at the new position.

esriKeepEndAttributes

2

If an extension is performed at an end, do not extrapolate the end-segment's attributes for the new point. Instead, make its attributes the same as the current end. Incompatible with esriNoAttributes.

esriNoEndAttributes

4

If an extension is performed at an end, do not extrapolate the end-segment's attributes for the new point. Instead, make its attributes be empty. Incompatible with esriKeepAttributes.

esriNoExtendAtFrom

8

Do not extend the 'from' end of any path.

esriNoExtendAtTo

16

Do not extend the 'to' end of any path.

 TrimExtend

 

See Also

IGeometryServer2 Interface