DataServiceCollection<T>.Clear 方法 (Boolean)
移除集合中的所有项,并选择性地分离 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 中分离出来。