SortedDictionary.System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Add メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > SortedDictionary.System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Add メソッドの意味・解説 

SortedDictionary.System.Collections.Generic.ICollection>.Add メソッド

メモ : このメソッドは、.NET Framework version 2.0新しく追加されたものです。

ICollection に項目を追加します

名前空間: System.Collections.Generic
アセンブリ: System (system.dll 内)
構文構文

Private Sub System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Add
 ( _
    keyValuePair As KeyValuePair(Of TKey, TValue)
 _
) Implements ICollection(Of KeyValuePair(Of
 TKey, TValue)).Add
Dim instance As SortedDictionary(Of
 TKey, TValue)
Dim keyValuePair As KeyValuePair(Of
 TKey, TValue)

CType(instance, ICollection(Of KeyValuePair(Of
 TKey, TValue))).Add(keyValuePair)
void ICollection<KeyValuePair<TKey,TValue>>.Add (
    KeyValuePair<TKey,TValue> keyValuePair
)
private:
virtual void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Add
 (
    KeyValuePair<TKey, TValue> keyValuePair
) sealed = ICollection<KeyValuePair<TKey, TValue>>::Add

パラメータ

keyValuePair

ICollection に追加する KeyValuePair 構造体

例外例外
例外種類条件

ArgumentNullException

keyValuePairnull 参照 (Visual Basic では Nothing) です。

ArgumentException

同じキー持つ要素が、SortedDictionary に既に存在します

解説解説

キーnull 参照 (Visual Basic では Nothing) にすることはできませんが、値の型 TValue参照型である場合、値を null にすることはできます

このメソッドは O(log n) 操作です。ここで、nCount です。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
SortedDictionary ジェネリック クラス
SortedDictionary メンバ
System.Collections.Generic 名前空間
ICollection.IsReadOnly プロパティ



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

SortedDictionary.System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Add メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



SortedDictionary.System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Add メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS