ErrorModelValidator Constructor
Initializes a new instance of the ErrorModelValidator class.
Namespace: System.Web.Http.Validation.Validators
Assembly: System.Web.Http (in System.Web.Http.dll)
Syntax
'Declaration
Public Sub New ( _
validatorProviders As IEnumerable(Of ModelValidatorProvider), _
errorMessage As String _
)
'Usage
Dim validatorProviders As IEnumerable(Of ModelValidatorProvider)
Dim errorMessage As String
Dim instance As New ErrorModelValidator(validatorProviders, _
errorMessage)
public ErrorModelValidator(
IEnumerable<ModelValidatorProvider> validatorProviders,
string errorMessage
)
public:
ErrorModelValidator(
IEnumerable<ModelValidatorProvider^>^ validatorProviders,
String^ errorMessage
)
new :
validatorProviders:IEnumerable<ModelValidatorProvider> *
errorMessage:string -> ErrorModelValidator
public function ErrorModelValidator(
validatorProviders : IEnumerable<ModelValidatorProvider>,
errorMessage : String
)
Parameters
validatorProviders
Type: System.Collections.Generic.IEnumerable<ModelValidatorProvider>The list of model validator providers.
errorMessage
Type: System.StringThe error message for the exception.