ModelStore.Element.RegisterRelationshipClass<TReferencedInterface> Method
Used to register a relationship.
Namespace: Microsoft.Data.Schema.SchemaModel
Assembly: Microsoft.Data.Schema (in Microsoft.Data.Schema.dll)
Syntax
'Declaration
Protected Shared Function RegisterRelationshipClass(Of TReferencedInterface) ( _
elementClass As ElementClass, _
relationshipName As String, _
relationshipType As ModelRelationshipType, _
relationshipCardinality As ModelRelationshipCardinalityStyle, _
isOrderedComparison As Boolean _
) As RelationshipClass
'Usage
Dim elementClass As ElementClass
Dim relationshipName As String
Dim relationshipType As ModelRelationshipType
Dim relationshipCardinality As ModelRelationshipCardinalityStyle
Dim isOrderedComparison As Boolean
Dim returnValue As RelationshipClass
returnValue = ModelStore..::..Element.RegisterRelationshipClass(elementClass, _
relationshipName, relationshipType, _
relationshipCardinality, isOrderedComparison)
protected static RelationshipClass RegisterRelationshipClass<TReferencedInterface>(
ElementClass elementClass,
string relationshipName,
ModelRelationshipType relationshipType,
ModelRelationshipCardinalityStyle relationshipCardinality,
bool isOrderedComparison
)
protected:
generic<typename TReferencedInterface>
static RelationshipClass^ RegisterRelationshipClass(
ElementClass^ elementClass,
String^ relationshipName,
ModelRelationshipType relationshipType,
ModelRelationshipCardinalityStyle relationshipCardinality,
bool isOrderedComparison
)
JScript does not support generic types or methods.
static member RegisterRelationshipClass :
elementClass:ElementClass *
relationshipName:string *
relationshipType:ModelRelationshipType *
relationshipCardinality:ModelRelationshipCardinalityStyle *
isOrderedComparison:bool -> RelationshipClass
Type Parameters
- TReferencedInterface
Parameters
- elementClass
Type: Microsoft.Data.Schema.SchemaModel.ElementClass
The element class
- relationshipName
Type: System.String
The relationship name
- relationshipType
Type: Microsoft.Data.Schema.SchemaModel.ModelRelationshipType
The relationship type
- relationshipCardinality
Type: Microsoft.Data.Schema.SchemaModel.ModelRelationshipCardinalityStyle
The relationship cardinality style
- isOrderedComparison
Type: System.Boolean
Specifies whether ordered comparison
Return Value
Type: Microsoft.Data.Schema.SchemaModel.RelationshipClass
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.