Class MvcHandler
Selects the controller that will handle an HTTP request.
public class MvcHandler : IHttpAsyncHandler, IHttpHandler, IRequiresSessionState
- Inheritance
-
MvcHandler
- Implements
-
IHttpAsyncHandlerIHttpHandlerIRequiresSessionState
- Inherited Members
Constructors
MvcHandler(RequestContext)
Initializes a new instance of the MvcHandler class.
public MvcHandler(RequestContext requestContext)
Parameters
requestContext
RequestContextThe request context.
Exceptions
- ArgumentNullException
The
requestContext
parameter is null.
Fields
MvcVersionHeaderName
Contains the header name of the ASP.NET MVC version.
public static readonly string MvcVersionHeaderName
Field Value
Properties
DisableMvcResponseHeader
Gets or sets a value that indicates whether the MVC response header is disabled.
public static bool DisableMvcResponseHeader { get; set; }
Property Value
- bool
true if the MVC response header is disabled; otherwise, false.
IsReusable
Gets a value that indicates whether another request can use the System.Web.IHttpHandler instance.
protected virtual bool IsReusable { get; }
Property Value
- bool
true if the System.Web.IHttpHandler instance is reusable; otherwise, false.
RequestContext
Gets the request context.
public RequestContext RequestContext { get; }
Property Value
- RequestContext
The request context.
Methods
AddVersionHeader(HttpContextBase)
Adds the version header by using the specified HTTP context.
protected virtual void AddVersionHeader(HttpContextBase httpContext)
Parameters
httpContext
HttpContextBaseThe HTTP context.
BeginProcessRequest(HttpContext, AsyncCallback, object)
Called by ASP.NET to begin asynchronous request processing.
protected virtual IAsyncResult BeginProcessRequest(HttpContext httpContext, AsyncCallback callback, object state)
Parameters
httpContext
HttpContextThe HTTP context.
callback
AsyncCallbackThe asynchronous callback method.
state
objectThe state of the asynchronous object.
Returns
- IAsyncResult
The status of the asynchronous call.
BeginProcessRequest(HttpContextBase, AsyncCallback, object)
Called by ASP.NET to begin asynchronous request processing using the base HTTP context.
protected virtual IAsyncResult BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, object state)
Parameters
httpContext
HttpContextBaseThe HTTP context.
callback
AsyncCallbackThe asynchronous callback method.
state
objectThe state of the asynchronous object.
Returns
- IAsyncResult
The status of the asynchronous call.
EndProcessRequest(IAsyncResult)
Called by ASP.NET when asynchronous request processing has ended.
protected virtual void EndProcessRequest(IAsyncResult asyncResult)
Parameters
asyncResult
IAsyncResultThe asynchronous result.
ProcessRequest(HttpContext)
Processes the request by using the specified HTTP request context.
protected virtual void ProcessRequest(HttpContext httpContext)
Parameters
httpContext
HttpContextThe HTTP context.
ProcessRequest(HttpContextBase)
Processes the request by using the specified base HTTP request context.
protected virtual void ProcessRequest(HttpContextBase httpContext)
Parameters
httpContext
HttpContextBaseThe HTTP context.