DataServiceContext.AttachLink(Object, String, Object) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
通知 開始 DataServiceContext 追蹤定義實體物件間關係的指定連結。
public:
void AttachLink(System::Object ^ source, System::String ^ sourceProperty, System::Object ^ target);
public void AttachLink(object source, string sourceProperty, object target);
member this.AttachLink : obj * string * obj -> unit
Public Sub AttachLink (source As Object, sourceProperty As String, target As Object)
參數
- source
- Object
新連結中的來源物件。
- sourceProperty
- String
來源物件上代表來源與目標物件連結的屬性名稱。
- target
- Object
連結中綁定至此呼叫中指定的來源物件的目標物件。 目標物件必須是來源屬性所識別的類型或子類型。
例外狀況
source, , sourceProperty, target 為空。