GraphLinkCollection::GetOrCreate Method (String^, String^, Int32)

 

Attempts to get the link with the specified source, target and multilink index If not found, a new link will be created.

Namespace:   Microsoft.VisualStudio.GraphModel
Assembly:  Microsoft.VisualStudio.GraphModel (in Microsoft.VisualStudio.GraphModel.dll)

public:
GraphLink^ GetOrCreate(
	String^ sourceId,
	String^ targetId,
	int index
)

Parameters

sourceId
Type: System::String^

The source node id

targetId
Type: System::String^

The target node id

index
Type: System::Int32

The link index, which gives you multiple links between the same source and target node

Return Value

Type: Microsoft.VisualStudio.GraphModel::GraphLink^

The Link that was found or created

Return to top
Show: