DomainModel.CreateElementLink Method

Creates an element link of a specified type.

Namespace:  Microsoft.VisualStudio.Modeling
Assembly:  Microsoft.VisualStudio.Modeling.Sdk (in Microsoft.VisualStudio.Modeling.Sdk.dll)

Syntax

'宣言
Public Overridable Function CreateElementLink ( _
    partition As Partition, _
    elementLinkType As Type, _
    roleAssignments As RoleAssignment(), _
    propertyAssignments As PropertyAssignment() _
) As ElementLink
'使用
Dim instance As DomainModel
Dim partition As Partition
Dim elementLinkType As Type
Dim roleAssignments As RoleAssignment()
Dim propertyAssignments As PropertyAssignment()
Dim returnValue As ElementLink

returnValue = instance.CreateElementLink(partition, _
    elementLinkType, roleAssignments, _
    propertyAssignments)
public virtual ElementLink CreateElementLink(
    Partition partition,
    Type elementLinkType,
    RoleAssignment[] roleAssignments,
    PropertyAssignment[] propertyAssignments
)
public:
virtual ElementLink^ CreateElementLink(
    Partition^ partition, 
    Type^ elementLinkType, 
    array<RoleAssignment^>^ roleAssignments, 
    array<PropertyAssignment^>^ propertyAssignments
)
public function CreateElementLink(
    partition : Partition, 
    elementLinkType : Type, 
    roleAssignments : RoleAssignment[], 
    propertyAssignments : PropertyAssignment[]
) : ElementLink

Parameters

  • elementLinkType
    Type: System.Type

    Element link type to create, which belongs to this domain model.

  • roleAssignments
    Type: []

    An array of relationship role assignments for the new element link.

  • propertyAssignments
    Type: []

    An array of new element link property assignments.

Return Value

Type: Microsoft.VisualStudio.Modeling.ElementLink

The ElementLink created.

Permissions

See Also

Concepts

Domain Model in the Generated API

Reference

DomainModel Class

DomainModel Members

Microsoft.VisualStudio.Modeling Namespace