CollectionsUtil.CreateCaseInsensitiveHashtable CollectionsUtil.CreateCaseInsensitiveHashtable CollectionsUtil.CreateCaseInsensitiveHashtable CollectionsUtil.CreateCaseInsensitiveHashtable Method

定義

建立忽略字串大小寫的 Hashtable 類別的新執行個體。Creates a new instance of the Hashtable class that ignores the case of strings.

多載

CreateCaseInsensitiveHashtable() CreateCaseInsensitiveHashtable() CreateCaseInsensitiveHashtable() CreateCaseInsensitiveHashtable()

建立具有預設初始容量的 Hashtable 類別之新的區分大小寫執行個體。Creates a new case-insensitive instance of the Hashtable class with the default initial capacity.

CreateCaseInsensitiveHashtable(IDictionary) CreateCaseInsensitiveHashtable(IDictionary) CreateCaseInsensitiveHashtable(IDictionary) CreateCaseInsensitiveHashtable(IDictionary)

從指定的字典複製項目到具有與複製項目數相同的初始容量之 Hashtable 類別之新的不區分大小寫執行個體。Copies the entries from the specified dictionary to a new case-insensitive instance of the Hashtable class with the same initial capacity as the number of entries copied.

CreateCaseInsensitiveHashtable(Int32) CreateCaseInsensitiveHashtable(Int32) CreateCaseInsensitiveHashtable(Int32) CreateCaseInsensitiveHashtable(Int32)

建立具有指定初始容量的 Hashtable 類別之新的區分大小寫執行個體。Creates a new case-insensitive instance of the Hashtable class with the specified initial capacity.

CreateCaseInsensitiveHashtable() CreateCaseInsensitiveHashtable() CreateCaseInsensitiveHashtable() CreateCaseInsensitiveHashtable()

建立具有預設初始容量的 Hashtable 類別之新的區分大小寫執行個體。Creates a new case-insensitive instance of the Hashtable class with the default initial capacity.

public:
 static System::Collections::Hashtable ^ CreateCaseInsensitiveHashtable();
public static System.Collections.Hashtable CreateCaseInsensitiveHashtable ();
static member CreateCaseInsensitiveHashtable : unit -> System.Collections.Hashtable
Public Shared Function CreateCaseInsensitiveHashtable () As Hashtable

傳回

具有預設初始容量的 Hashtable 類別之新的區分大小寫執行個體。A new case-insensitive instance of the Hashtable class with the default initial capacity.

備註

而不是使用CreateCaseInsensitiveHashtable方法,請使用Hashtable.Hashtable(IEqualityComparer)建構函式來建立不區分大小寫Hashtable類別。Instead of using the CreateCaseInsensitiveHashtable method, use the Hashtable.Hashtable(IEqualityComparer) constructor to create a case-insensitive Hashtable class.

另請參閱

CreateCaseInsensitiveHashtable(IDictionary) CreateCaseInsensitiveHashtable(IDictionary) CreateCaseInsensitiveHashtable(IDictionary) CreateCaseInsensitiveHashtable(IDictionary)

從指定的字典複製項目到具有與複製項目數相同的初始容量之 Hashtable 類別之新的不區分大小寫執行個體。Copies the entries from the specified dictionary to a new case-insensitive instance of the Hashtable class with the same initial capacity as the number of entries copied.

public:
 static System::Collections::Hashtable ^ CreateCaseInsensitiveHashtable(System::Collections::IDictionary ^ d);
public static System.Collections.Hashtable CreateCaseInsensitiveHashtable (System.Collections.IDictionary d);
static member CreateCaseInsensitiveHashtable : System.Collections.IDictionary -> System.Collections.Hashtable
Public Shared Function CreateCaseInsensitiveHashtable (d As IDictionary) As Hashtable

參數

d
IDictionary IDictionary IDictionary IDictionary

要複製至新的不區分大小寫之 IDictionaryHashtableThe IDictionary to copy to a new case-insensitive Hashtable.

傳回

Hashtable 類別之新的不區分大小寫執行個體,含有來自指定 IDictionary 的項目。A new case-insensitive instance of the Hashtable class containing the entries from the specified IDictionary.

例外狀況

備註

而不是使用CreateCaseInsensitiveHashtable方法,請使用Hashtable.Hashtable(IDictionary, IEqualityComparer)建構函式來建立不區分大小寫Hashtable類別。Instead of using the CreateCaseInsensitiveHashtable method, use the Hashtable.Hashtable(IDictionary, IEqualityComparer) constructor to create a case-insensitive Hashtable class.

另請參閱

CreateCaseInsensitiveHashtable(Int32) CreateCaseInsensitiveHashtable(Int32) CreateCaseInsensitiveHashtable(Int32) CreateCaseInsensitiveHashtable(Int32)

建立具有指定初始容量的 Hashtable 類別之新的區分大小寫執行個體。Creates a new case-insensitive instance of the Hashtable class with the specified initial capacity.

public:
 static System::Collections::Hashtable ^ CreateCaseInsensitiveHashtable(int capacity);
public static System.Collections.Hashtable CreateCaseInsensitiveHashtable (int capacity);
static member CreateCaseInsensitiveHashtable : int -> System.Collections.Hashtable
Public Shared Function CreateCaseInsensitiveHashtable (capacity As Integer) As Hashtable

參數

capacity
Int32 Int32 Int32 Int32

Hashtable 可初始包含項目的大約數目。The approximate number of entries that the Hashtable can initially contain.

傳回

具有指定初始容量的 Hashtable 類別之新的區分大小寫執行個體。A new case-insensitive instance of the Hashtable class with the specified initial capacity.

例外狀況

備註

而不是使用CreateCaseInsensitiveHashtable方法,請使用Hashtable.Hashtable(Int32, IEqualityComparer)建構函式來建立不區分大小寫Hashtable類別。Instead of using the CreateCaseInsensitiveHashtable method, use the Hashtable.Hashtable(Int32, IEqualityComparer) constructor to create a case-insensitive Hashtable class.

另請參閱

適用於