共用方式為


ExtensionMethods.GetAnnotationValue 方法 (IEdmModel, IEdmElement, String, String)

取得對應至指定之命名空間及提供之名稱的註釋值。

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

語法

'宣告
<ExtensionAttribute> _
Public Shared Function GetAnnotationValue ( _
    model As IEdmModel, _
    element As IEdmElement, _
    namespaceName As String, _
    localName As String _
) As Object
'用途
Dim model As IEdmModel
Dim element As IEdmElement
Dim namespaceName As String
Dim localName As String
Dim returnValue As Object

returnValue = model.GetAnnotationValue(element, _
    namespaceName, localName)
public static Object GetAnnotationValue(
    this IEdmModel model,
    IEdmElement element,
    string namespaceName,
    string localName
)
[ExtensionAttribute]
public:
static Object^ GetAnnotationValue(
    IEdmModel^ model, 
    IEdmElement^ element, 
    String^ namespaceName, 
    String^ localName
)
static member GetAnnotationValue : 
        model:IEdmModel * 
        element:IEdmElement * 
        namespaceName:string * 
        localName:string -> Object 
public static function GetAnnotationValue(
    model : IEdmModel, 
    element : IEdmElement, 
    namespaceName : String, 
    localName : String
) : Object

參數

  • localName
    型別:System.String
    命名空間內的註釋名稱。

傳回值

型別:System.Object
要求的註釋值 (如果有的話),否則為 null。

使用注意事項

在 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)

請參閱

參考

ExtensionMethods 類別

GetAnnotationValue 多載

Microsoft.Data.Edm 命名空間