共用方式為


SerializationExtensionMethods.SetAssociationSetAnnotations 方法

設定用於實體集導覽目標之序列化關聯集的註釋。

命名空間:  Microsoft.Data.Edm.Csdl
組件:  Microsoft.Data.Edm (在 Microsoft.Data.Edm.dll 中)

語法

'宣告
<ExtensionAttribute> _
Public Shared Sub SetAssociationSetAnnotations ( _
    model As IEdmModel, _
    entitySet As IEdmEntitySet, _
    property As IEdmNavigationProperty, _
    annotations As IEnumerable(Of IEdmDirectValueAnnotation), _
    end1Annotations As IEnumerable(Of IEdmDirectValueAnnotation), _
    end2Annotations As IEnumerable(Of IEdmDirectValueAnnotation) _
)
'用途
Dim model As IEdmModel
Dim entitySet As IEdmEntitySet
Dim property As IEdmNavigationProperty
Dim annotations As IEnumerable(Of IEdmDirectValueAnnotation)
Dim end1Annotations As IEnumerable(Of IEdmDirectValueAnnotation)
Dim end2Annotations As IEnumerable(Of IEdmDirectValueAnnotation)

model.SetAssociationSetAnnotations(entitySet, _
    property, annotations, end1Annotations, _
    end2Annotations)
public static void SetAssociationSetAnnotations(
    this IEdmModel model,
    IEdmEntitySet entitySet,
    IEdmNavigationProperty property,
    IEnumerable<IEdmDirectValueAnnotation> annotations,
    IEnumerable<IEdmDirectValueAnnotation> end1Annotations,
    IEnumerable<IEdmDirectValueAnnotation> end2Annotations
)
[ExtensionAttribute]
public:
static void SetAssociationSetAnnotations(
    IEdmModel^ model, 
    IEdmEntitySet^ entitySet, 
    IEdmNavigationProperty^ property, 
    IEnumerable<IEdmDirectValueAnnotation^>^ annotations, 
    IEnumerable<IEdmDirectValueAnnotation^>^ end1Annotations, 
    IEnumerable<IEdmDirectValueAnnotation^>^ end2Annotations
)
static member SetAssociationSetAnnotations : 
        model:IEdmModel * 
        entitySet:IEdmEntitySet * 
        property:IEdmNavigationProperty * 
        annotations:IEnumerable<IEdmDirectValueAnnotation> * 
        end1Annotations:IEnumerable<IEdmDirectValueAnnotation> * 
        end2Annotations:IEnumerable<IEdmDirectValueAnnotation> -> unit 
public static function SetAssociationSetAnnotations(
    model : IEdmModel, 
    entitySet : IEdmEntitySet, 
    property : IEdmNavigationProperty, 
    annotations : IEnumerable<IEdmDirectValueAnnotation>, 
    end1Annotations : IEnumerable<IEdmDirectValueAnnotation>, 
    end2Annotations : IEnumerable<IEdmDirectValueAnnotation>
)

參數

使用注意事項

在 Visual Basic 及 C# 中,您可以在任何型別 IEdmModel 的物件上將這個方法做為執行個體方法呼叫。使用執行個體方法語法呼叫這個方法時,請省略第一個參數。如需詳細資訊,請參閱 https://msdn.microsoft.com/zh-tw/library/bb384936(v=vs.103)https://msdn.microsoft.com/zh-tw/library/bb383977(v=vs.103)

請參閱

參考

SerializationExtensionMethods 類別

Microsoft.Data.Edm.Csdl 命名空間