Edit

Share via


RequestValidator Constructor

Definition

Initializes a new instance of the RequestValidator class.

public:
 RequestValidator();
public RequestValidator ();
Public Sub New ()

Remarks

The RequestValidator class has a parameterless constructor. When a new instance of the class is initialized, an internal method retrieves custom validation details from the application's configuration information. The configuration details are contained in the HttpRuntimeSection section. For more information, see httpRuntime Element (ASP.NET Settings Schema) and the RequestValidationType attribute.

During initialization, a single instance of the RequestValidator class is created, and a reference to the instance is maintained in the Current property. ASP.NET does not create a new request validator instance per request. Therefore, custom implementations of the RequestValidator class must be thread-safe.

Applies to