AssociatedValidatorProvider.GetValidators メソッド

定義

モデルの検証コントロールを取得します。

オーバーロード

名前 説明
GetValidators(ModelMetadata, ModelBindingExecutionContext)

指定したメタデータと実行コンテキストを使用して、モデルの検証コントロールを取得します。

GetValidators(ModelMetadata, ModelBindingExecutionContext, IEnumerable<Attribute>)

派生型で実装された場合は、指定したメタデータ、実行コンテキスト、および属性を使用して、モデルの検証コントロールを取得します。

GetValidators(ModelMetadata, ModelBindingExecutionContext)

指定したメタデータと実行コンテキストを使用して、モデルの検証コントロールを取得します。

public:
 override System::Collections::Generic::IEnumerable<System::Web::ModelBinding::ModelValidator ^> ^ GetValidators(System::Web::ModelBinding::ModelMetadata ^ metadata, System::Web::ModelBinding::ModelBindingExecutionContext ^ context);
public override sealed System.Collections.Generic.IEnumerable<System.Web.ModelBinding.ModelValidator> GetValidators(System.Web.ModelBinding.ModelMetadata metadata, System.Web.ModelBinding.ModelBindingExecutionContext context);
override this.GetValidators : System.Web.ModelBinding.ModelMetadata * System.Web.ModelBinding.ModelBindingExecutionContext -> seq<System.Web.ModelBinding.ModelValidator>
Public Overrides NotOverridable Function GetValidators (metadata As ModelMetadata, context As ModelBindingExecutionContext) As IEnumerable(Of ModelValidator)

パラメーター

metadata
ModelMetadata

メタデータ。

context
ModelBindingExecutionContext

実行コンテキスト。

返品

検証コントロール。

例外

metadataまたはcontextパラメーターがnull

メタデータ内のプロパティ名は、コンテナーの種類のプロパティの 1 つを参照していません。

適用対象

GetValidators(ModelMetadata, ModelBindingExecutionContext, IEnumerable<Attribute>)

派生型で実装された場合は、指定したメタデータ、実行コンテキスト、および属性を使用して、モデルの検証コントロールを取得します。

protected:
 abstract System::Collections::Generic::IEnumerable<System::Web::ModelBinding::ModelValidator ^> ^ GetValidators(System::Web::ModelBinding::ModelMetadata ^ metadata, System::Web::ModelBinding::ModelBindingExecutionContext ^ context, System::Collections::Generic::IEnumerable<Attribute ^> ^ attributes);
protected abstract System.Collections.Generic.IEnumerable<System.Web.ModelBinding.ModelValidator> GetValidators(System.Web.ModelBinding.ModelMetadata metadata, System.Web.ModelBinding.ModelBindingExecutionContext context, System.Collections.Generic.IEnumerable<Attribute> attributes);
override this.GetValidators : System.Web.ModelBinding.ModelMetadata * System.Web.ModelBinding.ModelBindingExecutionContext * seq<Attribute> -> seq<System.Web.ModelBinding.ModelValidator>
Protected MustOverride Function GetValidators (metadata As ModelMetadata, context As ModelBindingExecutionContext, attributes As IEnumerable(Of Attribute)) As IEnumerable(Of ModelValidator)

パラメーター

metadata
ModelMetadata

メタデータ。

context
ModelBindingExecutionContext

実行コンテキスト。

attributes
IEnumerable<Attribute>

属性。

返品

検証コントロール。

適用対象