Managed Collection. Clear 方法
public: void Clear();
public void Clear ();
member this.Clear : unit -> unit
Public Sub Clear ()
方法會在 OnClear Clear 呼叫方法之前呼叫，並在完成將專案 OnClearComplete Clear 從集合中移除之後呼叫方法。The OnClear method is called before the Clear method is called, and the OnClearComplete method is called after Clear has finished removing elements from the collection.