ModelStateDictionary.Add メソッド

定義

オーバーロード

Add(KeyValuePair<String,ModelState>)

指定された項目をモデル状態ディクショナリに追加します。

Add(String, ModelState)

指定されたキーと値を持つ要素をモデル状態ディクショナリに追加します。

Add(KeyValuePair<String,ModelState>)

指定された項目をモデル状態ディクショナリに追加します。

public void Add (System.Collections.Generic.KeyValuePair<string,System.Web.Mvc.ModelState> item);
abstract member Add : System.Collections.Generic.KeyValuePair<string, System.Web.Mvc.ModelState> -> unit
override this.Add : System.Collections.Generic.KeyValuePair<string, System.Web.Mvc.ModelState> -> unit
Public Sub Add (item As KeyValuePair(Of String, ModelState))

パラメーター

item
KeyValuePair<String,ModelState>

モデル状態ディクショナリに追加するオブジェクト。

実装

例外

モデル状態ディクショナリが読み取り専用です。

適用対象

Add(String, ModelState)

指定されたキーと値を持つ要素をモデル状態ディクショナリに追加します。

public void Add (string key, System.Web.Mvc.ModelState value);
abstract member Add : string * System.Web.Mvc.ModelState -> unit
override this.Add : string * System.Web.Mvc.ModelState -> unit
Public Sub Add (key As String, value As ModelState)

パラメーター

key
String

追加する要素のキー。

value
ModelState

追加する要素の値。

実装

例外

モデル状態ディクショナリが読み取り専用です。

key が null です。

指定されたキーを持つ要素が、既にモデル状態ディクショナリにあります。

適用対象