從集合中移除所有項目,並選擇性地從 DataServiceContext 卸離所有項目。
命名空間: System.Data.Services.Client
組件: Microsoft.Data.Services.Client (在 Microsoft.Data.Services.Client.dll 中)
語法
'宣告
Public Sub Clear ( _
stopTracking As Boolean _
)
'用途
Dim instance As DataServiceCollection
Dim stopTracking As Boolean
instance.Clear(stopTracking)
public void Clear(
bool stopTracking
)
public:
void Clear(
bool stopTracking
)
member Clear :
stopTracking:bool -> unit
public function Clear(
stopTracking : boolean
)
參數
- stopTracking
型別:System.Boolean
如果為 true,則從 DataServiceContext 卸離所有項目。
備註
當項目卸離時,資料圖形中的所有相關物件也會從 DataServiceContext 卸離。