ArcObjects Library Reference (NetworkAnalysis)  

ITraceFlowSolver2.FindSource Method

Finds a path upstream to a source or downstream to a sink, depending on the specified flow method.

[Visual Basic .NET]
Public Sub FindSource ( _
    ByVal flowMethod As esriFlowMethod, _
    ByVal objFn As esriShortestPathObjFn, _
    ByRef junctionEIDs As IEnumNetEID, _
    ByRef edgeEIDs As IEnumNetEID, _
    ByVal Count As Integer, _
    ByRef segmentCosts As Object _
)
[C#]
public void FindSource (
    esriFlowMethod flowMethod,
    esriShortestPathObjFn objFn,
    ref IEnumNetEID junctionEIDs,
    ref IEnumNetEID edgeEIDs,
    ref int Count,
    ref object segmentCosts
);
[C++]
HRESULT FindSource(
  esriFlowMethod flowMethod,
  esriShortestPathObjFn objFn,
  IEnumNetEID** junctionEIDs,
  IEnumNetEID** edgeEIDs,
  long Count,
  VARIANT* segmentCosts
);
[C++]

Parameters

flowMethod [in]

  flowMethod is a parameter of type esriFlowMethod

objFn [in]

  objFn is a parameter of type esriShortestPathObjFn

junctionEIDs [out]

  junctionEIDs is a parameter of type IEnumNetEID

edgeEIDs [out]

  edgeEIDs is a parameter of type IEnumNetEID

Count [in]   Count is a parameter of type long segmentCosts [in, out]   segmentCosts is a parameter of type VARIANT

Product Availability

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

Remarks

The FlowMethod parameter determines whether the trace solver traces upstream, downstream, or on all connected edges.  If you would like to allow or restrict tracing on edges with indeterminate or uninitialized flow, be sure to set the ITraceFlowSolver::TraceIndeterminateFlow property prior to calling this trace solver.

The objFn parameter specifies the objective function of the trace solver. Depending on this parameter, the trace solver will either attempt to minimize the total cost of the paths to the source, or will attempt to minimize the maximum cost of any single element in the paths to the source.

The Count is the number of path segments to be returned by the trace solver. It is equivalent to the number of flags being passed into the trace solver. The Count is also the size of the array passed into the segmentCosts parameter.

The trace solver will return the traced junction and edge element IDs in the junctionEIDs and edgeEIDs parameters respectively, and will return the cost of each segment in the segmentCosts array.

The traced element IDs are returned in the order that they were traced.

[C#]

This method is not callable from C#.  Please use ITraceFlowSolverGEN::FindSource.

[Visual Basic .NET]

This method is not callable from VB.NET.  Please use ITraceFlowSolverGEN::FindSource.

See Also

ITraceFlowSolver2 Interface