/// <summary> /// 停止下载 /// 取消当前正在下载的资源 /// 清空整个队列 /// </summary> public void StopDownload() { if (null != httpClient) { httpClient.Abort(); } downloadSortSet.Clear(); }
/// <summary> /// 当释放时 /// </summary> public void OnDestroy() { foreach (var current in destroy) { current.OnDestroy(); } update.Clear(); lateUpdate.Clear(); destroy.Clear(); loadSet.Clear(); }
/// <summary> /// 当释放时 /// </summary> public void OnDestroy() { dispatcher.Trigger(MonoDriverEvents.OnBeforeDestroy); container.Flush(); foreach (var current in destroy) { current.OnDestroy(); } update.Clear(); lateUpdate.Clear(); fixedUpdate.Clear(); onGui.Clear(); destroy.Clear(); loadSet.Clear(); dispatcher.Trigger(MonoDriverEvents.OnDestroyed); }
/// <summary> /// 当释放时 /// </summary> public void OnDestroy() { container.Flush(); foreach (var current in destroy) { current.OnDestroy(); } update.Clear(); lateUpdate.Clear(); fixedUpdate.Clear(); onGui.Clear(); destroy.Clear(); loadSet.Clear(); applicationFocus.Clear(); applicationPause.Clear(); applicationQuit.Clear(); }
public void ClearTest() { var master = new SortSet <int, int>(0.25, 32); for (var i = 0; i < 65536; i++) { master.Add(i, i); } master.Clear(); for (var i = 0; i < 65536; i++) { master.Add(i, i); } for (var i = 0; i < 65536; i++) { Assert.AreEqual(i, master.GetRank(i)); } Assert.AreEqual(65536, master.Count); }