NameValueCollection NameValueCollection NameValueCollection NameValueCollection Constructors

定義

多載

NameValueCollection() NameValueCollection() NameValueCollection()

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、有預設的初始容量,並採用預設的不區分大小寫的雜湊程式碼提供者和預設的不區分大小寫的比較子 (Comparer)。Initializes a new instance of the NameValueCollection class that is empty, has the default initial capacity and uses the default case-insensitive hash code provider and the default case-insensitive comparer.

NameValueCollection(IEqualityComparer) NameValueCollection(IEqualityComparer) NameValueCollection(IEqualityComparer) NameValueCollection(IEqualityComparer)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、具有預設的初始容量,並使用指定的 IEqualityComparer 物件。Initializes a new instance of the NameValueCollection class that is empty, has the default initial capacity, and uses the specified IEqualityComparer object.

NameValueCollection(NameValueCollection) NameValueCollection(NameValueCollection) NameValueCollection(NameValueCollection) NameValueCollection(NameValueCollection)

從指定的 NameValueCollection 複製項目至新的 NameValueCollection,使其具有與複製的項目數目一樣的初始容量,並使用與來源集合相同的雜湊程式碼提供者,以及相同的比較子。Copies the entries from the specified NameValueCollection to a new NameValueCollection with the same initial capacity as the number of entries copied and using the same hash code provider and the same comparer as the source collection.

NameValueCollection(Int32) NameValueCollection(Int32) NameValueCollection(Int32) NameValueCollection(Int32)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、有指定的初始容量,並採用預設的不區分大小寫的雜湊程式碼提供者和預設的不區分大小寫的比較子。Initializes a new instance of the NameValueCollection class that is empty, has the specified initial capacity and uses the default case-insensitive hash code provider and the default case-insensitive comparer.

NameValueCollection(IHashCodeProvider, IComparer) NameValueCollection(IHashCodeProvider, IComparer) NameValueCollection(IHashCodeProvider, IComparer) NameValueCollection(IHashCodeProvider, IComparer)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、有預設的初始容量,並採用指定的雜湊程式碼提供者和指定的比較子。Initializes a new instance of the NameValueCollection class that is empty, has the default initial capacity and uses the specified hash code provider and the specified comparer.

NameValueCollection(Int32, IEqualityComparer) NameValueCollection(Int32, IEqualityComparer) NameValueCollection(Int32, IEqualityComparer) NameValueCollection(Int32, IEqualityComparer)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、具有指定的初始容量,並使用指定的 IEqualityComparer 物件。Initializes a new instance of the NameValueCollection class that is empty, has the specified initial capacity, and uses the specified IEqualityComparer object.

NameValueCollection(Int32, NameValueCollection) NameValueCollection(Int32, NameValueCollection) NameValueCollection(Int32, NameValueCollection) NameValueCollection(Int32, NameValueCollection)

從指定的 NameValueCollection 複製項目至新的 NameValueCollection,使其具有指定的初始容量,或是與複製的項目數目一樣的初始容量,端視何者較大,並使用預設的不區分大小寫的雜湊程式碼提供者,以及預設的不區分大小寫的比較子。Copies the entries from the specified NameValueCollection to a new NameValueCollection with the specified initial capacity or the same initial capacity as the number of entries copied, whichever is greater, and using the default case-insensitive hash code provider and the default case-insensitive comparer.

NameValueCollection(SerializationInfo, StreamingContext) NameValueCollection(SerializationInfo, StreamingContext) NameValueCollection(SerializationInfo, StreamingContext) NameValueCollection(SerializationInfo, StreamingContext)

初始化 NameValueCollection 類別的新執行個體,這個執行個體可序列化,並使用指定的 SerializationInfoStreamingContextInitializes a new instance of the NameValueCollection class that is serializable and uses the specified SerializationInfo and StreamingContext.

NameValueCollection(Int32, IHashCodeProvider, IComparer) NameValueCollection(Int32, IHashCodeProvider, IComparer) NameValueCollection(Int32, IHashCodeProvider, IComparer) NameValueCollection(Int32, IHashCodeProvider, IComparer)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、具有指定的初始容量,並使用指定的雜湊碼提供者和指定的比較子。Initializes a new instance of the NameValueCollection class that is empty, has the specified initial capacity and uses the specified hash code provider and the specified comparer.

NameValueCollection() NameValueCollection() NameValueCollection()

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、有預設的初始容量,並採用預設的不區分大小寫的雜湊程式碼提供者和預設的不區分大小寫的比較子 (Comparer)。Initializes a new instance of the NameValueCollection class that is empty, has the default initial capacity and uses the default case-insensitive hash code provider and the default case-insensitive comparer.

public:
 NameValueCollection();
public NameValueCollection ();
Public Sub New ()

備註

容量NameValueCollection是的項目數,NameValueCollection可以保存。The capacity of a NameValueCollection is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 預設雜湊程式碼提供者CaseInsensitiveHashCodeProviderThe default hash code provider is the CaseInsensitiveHashCodeProvider.

比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal. 預設比較子是CaseInsensitiveComparerThe default comparer is the CaseInsensitiveComparer.

這個建構函式是 o (1) 的作業。This constructor is an O(1) operation.

另請參閱

NameValueCollection(IEqualityComparer) NameValueCollection(IEqualityComparer) NameValueCollection(IEqualityComparer) NameValueCollection(IEqualityComparer)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、具有預設的初始容量,並使用指定的 IEqualityComparer 物件。Initializes a new instance of the NameValueCollection class that is empty, has the default initial capacity, and uses the specified IEqualityComparer object.

public:
 NameValueCollection(System::Collections::IEqualityComparer ^ equalityComparer);
public NameValueCollection (System.Collections.IEqualityComparer equalityComparer);
new System.Collections.Specialized.NameValueCollection : System.Collections.IEqualityComparer -> System.Collections.Specialized.NameValueCollection
Public Sub New (equalityComparer As IEqualityComparer)

參數

equalityComparer
IEqualityComparer IEqualityComparer IEqualityComparer IEqualityComparer

IEqualityComparer 物件,可用來判斷兩個索引鍵是否相等,以及為集合中的索引鍵產生雜湊碼。The IEqualityComparer object to use to determine whether two keys are equal and to generate hash codes for the keys in the collection.

備註

營運NameValueCollection物件是項目數目,NameValueCollection可以保存。The capacity of a NameValueCollection object is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

IEqualityComparer物件結合的比較子和雜湊程式碼提供者。The IEqualityComparer object combines the comparer and the hash code provider. 雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal.

這個建構函式是 o (1) 的作業。This constructor is an O(1) operation.

另請參閱

NameValueCollection(NameValueCollection) NameValueCollection(NameValueCollection) NameValueCollection(NameValueCollection) NameValueCollection(NameValueCollection)

從指定的 NameValueCollection 複製項目至新的 NameValueCollection,使其具有與複製的項目數目一樣的初始容量,並使用與來源集合相同的雜湊程式碼提供者,以及相同的比較子。Copies the entries from the specified NameValueCollection to a new NameValueCollection with the same initial capacity as the number of entries copied and using the same hash code provider and the same comparer as the source collection.

public:
 NameValueCollection(System::Collections::Specialized::NameValueCollection ^ col);
public NameValueCollection (System.Collections.Specialized.NameValueCollection col);
new System.Collections.Specialized.NameValueCollection : System.Collections.Specialized.NameValueCollection -> System.Collections.Specialized.NameValueCollection
Public Sub New (col As NameValueCollection)

參數

例外狀況

備註

容量NameValueCollection是的項目數,NameValueCollection可以保存。The capacity of a NameValueCollection is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 預設雜湊程式碼提供者CaseInsensitiveHashCodeProviderThe default hash code provider is the CaseInsensitiveHashCodeProvider.

比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal. 預設比較子是CaseInsensitiveComparerThe default comparer is the CaseInsensitiveComparer.

新的項目NameValueCollection做為來源相同的順序排序NameValueCollectionThe elements of the new NameValueCollection are sorted in the same order as the source NameValueCollection.

這個建構函式是 O (n) 運算,其中n是中的項目數colThis constructor is an O(n) operation, where n is the number of elements in col.

另請參閱

NameValueCollection(Int32) NameValueCollection(Int32) NameValueCollection(Int32) NameValueCollection(Int32)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、有指定的初始容量,並採用預設的不區分大小寫的雜湊程式碼提供者和預設的不區分大小寫的比較子。Initializes a new instance of the NameValueCollection class that is empty, has the specified initial capacity and uses the default case-insensitive hash code provider and the default case-insensitive comparer.

public:
 NameValueCollection(int capacity);
public NameValueCollection (int capacity);
new System.Collections.Specialized.NameValueCollection : int -> System.Collections.Specialized.NameValueCollection
Public Sub New (capacity As Integer)

參數

capacity
Int32 Int32 Int32 Int32

NameValueCollection 可包含元素的初始數目。The initial number of entries that the NameValueCollection can contain.

例外狀況

備註

容量NameValueCollection是的項目數,NameValueCollection可以保存。The capacity of a NameValueCollection is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 預設雜湊程式碼提供者CaseInsensitiveHashCodeProviderThe default hash code provider is the CaseInsensitiveHashCodeProvider.

比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal. 預設比較子是CaseInsensitiveComparerThe default comparer is the CaseInsensitiveComparer.

這個建構函式是 O (n) 運算,其中ncapacityThis constructor is an O(n) operation, where n is capacity.

另請參閱

NameValueCollection(IHashCodeProvider, IComparer) NameValueCollection(IHashCodeProvider, IComparer) NameValueCollection(IHashCodeProvider, IComparer) NameValueCollection(IHashCodeProvider, IComparer)

警告

此 API 現已淘汰。

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、有預設的初始容量,並採用指定的雜湊程式碼提供者和指定的比較子。Initializes a new instance of the NameValueCollection class that is empty, has the default initial capacity and uses the specified hash code provider and the specified comparer.

public:
 NameValueCollection(System::Collections::IHashCodeProvider ^ hashProvider, System::Collections::IComparer ^ comparer);
[System.Obsolete("Please use NameValueCollection(IEqualityComparer) instead.")]
public NameValueCollection (System.Collections.IHashCodeProvider hashProvider, System.Collections.IComparer comparer);
new System.Collections.Specialized.NameValueCollection : System.Collections.IHashCodeProvider * System.Collections.IComparer -> System.Collections.Specialized.NameValueCollection
Public Sub New (hashProvider As IHashCodeProvider, comparer As IComparer)

參數

hashProvider
IHashCodeProvider IHashCodeProvider IHashCodeProvider IHashCodeProvider

IHashCodeProvider,將為 NameValueCollection 中的所有索引鍵提供雜湊程式碼。The IHashCodeProvider that will supply the hash codes for all keys in the NameValueCollection.

comparer
IComparer IComparer IComparer IComparer

IComparer,可用來判斷兩個索引鍵是否相等。The IComparer to use to determine whether two keys are equal.

備註

容量NameValueCollection是的項目數,NameValueCollection可以保存。The capacity of a NameValueCollection is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 預設雜湊程式碼提供者CaseInsensitiveHashCodeProviderThe default hash code provider is the CaseInsensitiveHashCodeProvider.

比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal. 預設比較子是CaseInsensitiveComparerThe default comparer is the CaseInsensitiveComparer.

這個建構函式是 o (1) 的作業。This constructor is an O(1) operation.

另請參閱

NameValueCollection(Int32, IEqualityComparer) NameValueCollection(Int32, IEqualityComparer) NameValueCollection(Int32, IEqualityComparer) NameValueCollection(Int32, IEqualityComparer)

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、具有指定的初始容量,並使用指定的 IEqualityComparer 物件。Initializes a new instance of the NameValueCollection class that is empty, has the specified initial capacity, and uses the specified IEqualityComparer object.

public:
 NameValueCollection(int capacity, System::Collections::IEqualityComparer ^ equalityComparer);
public NameValueCollection (int capacity, System.Collections.IEqualityComparer equalityComparer);
new System.Collections.Specialized.NameValueCollection : int * System.Collections.IEqualityComparer -> System.Collections.Specialized.NameValueCollection
Public Sub New (capacity As Integer, equalityComparer As IEqualityComparer)

參數

capacity
Int32 Int32 Int32 Int32

NameValueCollection 物件可包含的初始項目數。The initial number of entries that the NameValueCollection object can contain.

equalityComparer
IEqualityComparer IEqualityComparer IEqualityComparer IEqualityComparer

IEqualityComparer 物件,可用來判斷兩個索引鍵是否相等,以及為集合中的索引鍵產生雜湊碼。The IEqualityComparer object to use to determine whether two keys are equal and to generate hash codes for the keys in the collection.

例外狀況

備註

營運NameValueCollection物件是項目數目,NameValueCollection可以保存。The capacity of a NameValueCollection object is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

IEqualityComparer物件結合的比較子和雜湊程式碼提供者。The IEqualityComparer object combines the comparer and the hash code provider. 雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal.

這個建構函式是 O (n) 運算,其中ncapacity參數。This constructor is an O(n) operation, where n is the capacity parameter.

另請參閱

NameValueCollection(Int32, NameValueCollection) NameValueCollection(Int32, NameValueCollection) NameValueCollection(Int32, NameValueCollection) NameValueCollection(Int32, NameValueCollection)

從指定的 NameValueCollection 複製項目至新的 NameValueCollection,使其具有指定的初始容量,或是與複製的項目數目一樣的初始容量,端視何者較大,並使用預設的不區分大小寫的雜湊程式碼提供者,以及預設的不區分大小寫的比較子。Copies the entries from the specified NameValueCollection to a new NameValueCollection with the specified initial capacity or the same initial capacity as the number of entries copied, whichever is greater, and using the default case-insensitive hash code provider and the default case-insensitive comparer.

public:
 NameValueCollection(int capacity, System::Collections::Specialized::NameValueCollection ^ col);
public NameValueCollection (int capacity, System.Collections.Specialized.NameValueCollection col);
new System.Collections.Specialized.NameValueCollection : int * System.Collections.Specialized.NameValueCollection -> System.Collections.Specialized.NameValueCollection
Public Sub New (capacity As Integer, col As NameValueCollection)

參數

capacity
Int32 Int32 Int32 Int32

NameValueCollection 可包含元素的初始數目。The initial number of entries that the NameValueCollection can contain.

例外狀況

備註

容量NameValueCollection是的項目數,NameValueCollection可以保存。The capacity of a NameValueCollection is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 預設雜湊程式碼提供者CaseInsensitiveHashCodeProviderThe default hash code provider is the CaseInsensitiveHashCodeProvider.

比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal. 預設比較子是CaseInsensitiveComparerThe default comparer is the CaseInsensitiveComparer.

這個建構函式是 O (n) 運算,其中ncapacityThis constructor is an O(n) operation, where n is capacity. 如果中的項目數col大於capacity,這個建構函式會變成 O (n + m) 作業,其中ncapacitym數目中的項目colIf the number of elements in col is greater than capacity, this constructor becomes an O(n + m) operation, where n is capacity and m is the number of elements in col.

另請參閱

NameValueCollection(SerializationInfo, StreamingContext) NameValueCollection(SerializationInfo, StreamingContext) NameValueCollection(SerializationInfo, StreamingContext) NameValueCollection(SerializationInfo, StreamingContext)

初始化 NameValueCollection 類別的新執行個體,這個執行個體可序列化,並使用指定的 SerializationInfoStreamingContextInitializes a new instance of the NameValueCollection class that is serializable and uses the specified SerializationInfo and StreamingContext.

protected:
 NameValueCollection(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected NameValueCollection (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.Collections.Specialized.NameValueCollection : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Collections.Specialized.NameValueCollection
Protected Sub New (info As SerializationInfo, context As StreamingContext)

參數

info
SerializationInfo SerializationInfo SerializationInfo SerializationInfo

SerializationInfo 物件,包含將新的 NameValueCollection 執行個體序列化所需的資訊。A SerializationInfo object that contains the information required to serialize the new NameValueCollection instance.

context
StreamingContext StreamingContext StreamingContext StreamingContext

StreamingContext 物件,包含與新 NameValueCollection 執行個體相關聯之已序列資料流的來源和目的地。A StreamingContext object that contains the source and destination of the serialized stream associated with the new NameValueCollection instance.

備註

這個建構函式是 o (1) 的作業。This constructor is an O(1) operation.

另請參閱

NameValueCollection(Int32, IHashCodeProvider, IComparer) NameValueCollection(Int32, IHashCodeProvider, IComparer) NameValueCollection(Int32, IHashCodeProvider, IComparer) NameValueCollection(Int32, IHashCodeProvider, IComparer)

警告

此 API 現已淘汰。

初始化 NameValueCollection 類別的新執行個體,這個執行個體是空白的、具有指定的初始容量,並使用指定的雜湊碼提供者和指定的比較子。Initializes a new instance of the NameValueCollection class that is empty, has the specified initial capacity and uses the specified hash code provider and the specified comparer.

public:
 NameValueCollection(int capacity, System::Collections::IHashCodeProvider ^ hashProvider, System::Collections::IComparer ^ comparer);
[System.Obsolete("Please use NameValueCollection(Int32, IEqualityComparer) instead.")]
public NameValueCollection (int capacity, System.Collections.IHashCodeProvider hashProvider, System.Collections.IComparer comparer);
new System.Collections.Specialized.NameValueCollection : int * System.Collections.IHashCodeProvider * System.Collections.IComparer -> System.Collections.Specialized.NameValueCollection
Public Sub New (capacity As Integer, hashProvider As IHashCodeProvider, comparer As IComparer)

參數

capacity
Int32 Int32 Int32 Int32

NameValueCollection 可包含元素的初始數目。The initial number of entries that the NameValueCollection can contain.

hashProvider
IHashCodeProvider IHashCodeProvider IHashCodeProvider IHashCodeProvider

IHashCodeProvider,將為 NameValueCollection 中的所有索引鍵提供雜湊程式碼。The IHashCodeProvider that will supply the hash codes for all keys in the NameValueCollection.

comparer
IComparer IComparer IComparer IComparer

IComparer,可用來判斷兩個索引鍵是否相等。The IComparer to use to determine whether two keys are equal.

例外狀況

備註

容量NameValueCollection是的項目數,NameValueCollection可以保存。The capacity of a NameValueCollection is the number of elements that the NameValueCollection can hold. 當項目新增至NameValueCollection,自動增加容量的要求以重新配置內部陣列。As elements are added to a NameValueCollection, the capacity is automatically increased as required by reallocating the internal array.

如果可以估計集合的大小,指定初始容量,就不需要執行數項調整大小作業新增項目時NameValueCollectionIf the size of the collection can be estimated, specifying the initial capacity eliminates the need to perform a number of resizing operations while adding elements to the NameValueCollection.

雜湊程式碼提供者上精心篩選中的索引鍵的雜湊碼NameValueCollectionThe hash code provider dispenses hash codes for keys in the NameValueCollection. 預設雜湊程式碼提供者CaseInsensitiveHashCodeProviderThe default hash code provider is the CaseInsensitiveHashCodeProvider.

比較子判斷兩個索引鍵是否相等。The comparer determines whether two keys are equal. 預設比較子是CaseInsensitiveComparerThe default comparer is the CaseInsensitiveComparer.

這個建構函式是 O (n) 運算,其中ncapacityThis constructor is an O(n) operation, where n is capacity.

另請參閱

適用於