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


INetworkForwardStarAdjacencies.QueryEdge Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geodatabase > ESRI.ArcGIS.GeoDatabase > Interfaces > IN > INetworkForwardStarAdjacencies Interface > INetworkForwardStarAdjacencies.QueryEdge Method
ArcGIS Developer Help

INetworkForwardStarAdjacencies.QueryEdge Method

Queries the adjacent edge element at the specified index.

[Visual Basic .NET]
Public Sub QueryEdge ( _
    ByVal Index As Integer, _
    ByVal adjacentEdge As INetworkEdge, _
    ByRef fromPosition As Double, _
    ByRef toPosition As Double _
)
[C#]
public void QueryEdge (
    int Index,
    INetworkEdge adjacentEdge,
    ref double fromPosition,
    ref double toPosition
);
[C++]
HRESULT QueryEdge(
  long Index,
  INetworkEdge* adjacentEdge,
  System.Double* fromPosition,
  System.Double* toPosition
);
[C++]
Parameters
Index [in]

Index is a parameter of type long adjacentEdge [in]
adjacentEdge is a parameter of type INetworkEdge* fromPosition [out]
fromPosition is a parameter of type double* toPosition [out]
toPosition is a parameter of type double*

Product Availability

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

Remarks

The QueryEdge method returns the edge element that is adjacent to the atJunction at the specified index.

The index values range from 0 to (Count - 1).

The QueryEdge method requires an instantiated NetworkEdge object to be passed in as a parameter.  You can create an empty NetworkEdge object by using the INetworkQuery::CreateNetworkElement method.

The fromPosition and toPosition parameters indicate the range of accessible positions (starting from the atJunction) along the network edge element that was queried. The position values can range from 0.0 to 1.0, where 0.0 is at the starting end of the edge element and 1.0 is at the terminating end of the edge element. The fromPosition value will always be less than or equal to the toPosition value, regardless of the Direction property of the edge element. In most cases, the entire edge element will be accessible, so the fromPosition parameter will be returned as 0.0 and the toPosition parameter will be returned as 1.0.

In the case when only a portion of the edge element is accessible, this means the edge has been partially restricted by a call to the INetworkForwardStarEx::AddEdgeRestriction method.

See Also

INetworkForwardStarAdjacencies Interface