You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// Initializes a new instance of the <see cref="DisposableConcurrentDictionary{TKey, TValue}" /> class with the specified concurrency level and initial capacity.
41
+
/// </remarks>
42
+
/// <param name="concurrencyLevel">并发级别,即字典可以同时支持的线程数,必须大于0 / The number of threads that can access the dictionary concurrently, must be greater than 0.</param>
43
+
/// <param name="capacity">字典的初始容量,必须大于等于0 / The initial number of elements that the dictionary can contain, must be greater than or equal to 0.</param>
44
+
/// <exception cref="ArgumentOutOfRangeException">当 <paramref name="concurrencyLevel"/> 小于等于 0 或 <paramref name="capacity"/> 小于 0 时抛出 / Thrown when <paramref name="concurrencyLevel"/> is less than or equal to 0 or <paramref name="capacity"/> is less than 0.</exception>
@@ -49,6 +64,9 @@ public DisposableConcurrentDictionary(IEqualityComparer<NullObject<TKey>> compar
49
64
/// <summary>
50
65
/// 释放资源。
51
66
/// </summary>
67
+
/// <remarks>
68
+
/// Releases all resources used by this instance.
69
+
/// </remarks>
52
70
publicvoidDispose()
53
71
{
54
72
if(_isDisposed)
@@ -64,6 +82,9 @@ public void Dispose()
64
82
/// <summary>
65
83
/// 终结器,确保未释放的资源在对象被垃圾回收时被释放。
66
84
/// </summary>
85
+
/// <remarks>
86
+
/// Finalizer to ensure unmanaged resources are released when the object is garbage collected.
87
+
/// </remarks>
67
88
~DisposableConcurrentDictionary()
68
89
{
69
90
Dispose(false);
@@ -72,7 +93,10 @@ public void Dispose()
72
93
/// <summary>
73
94
/// 释放资源。
74
95
/// </summary>
75
-
/// <param name="disposing">指示是否应释放托管资源。</param>
96
+
/// <remarks>
97
+
/// Releases the unmanaged resources used by the <see cref="DisposableConcurrentDictionary{TKey, TValue}"/> and optionally releases the managed resources.
98
+
/// </remarks>
99
+
/// <param name="disposing">指示是否应释放托管资源 / true to release both managed and unmanaged resources; false to release only unmanaged resources.</param>
0 commit comments