Freigeben über


HttpActionContext Class

Contains information for the executing action.

Inheritance Hierarchy

System.Object
  System.Web.Http.Controllers.HttpActionContext

Namespace:  System.Web.Http.Controllers
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

'Declaration
Public Class HttpActionContext
'Usage
Dim instance As HttpActionContext
public class HttpActionContext
public ref class HttpActionContext
type HttpActionContext =  class end
public class HttpActionContext

The HttpActionContext type exposes the following members.

Constructors

  Name Description
Public method HttpActionContext() Initializes a new instance of the HttpActionContext class.
Public method HttpActionContext(HttpControllerContext, HttpActionDescriptor) Initializes a new instance of the HttpActionContext class.

Top

Properties

  Name Description
Public property ActionArguments Gets a list of action arguments.
Public property ActionDescriptor Gets or sets the action descriptor for the action context.
Public property ControllerContext Gets or sets the controller context.
Public property ModelState Gets the model state dictionary for the context.
Public property Request Gets the request message for the action context.
Public property Response Gets or sets the response message for the action context.

Top

Methods

  Name Description
Public method Equals (Inherited from Object.)
Protected method Finalize (Inherited from Object.)
Public method GetHashCode (Inherited from Object.)
Public method GetType (Inherited from Object.)
Protected method MemberwiseClone (Inherited from Object.)
Public method ToString (Inherited from Object.)

Top

Extension Methods

  Name Description
Public Extension Method Bind(ModelBindingContext) Overloaded. Binds the model to a value by using the specified controller context and binding context. (Defined by HttpActionContextExtensions.)
Public Extension Method Bind(ModelBindingContext, IEnumerable<IModelBinder>) Overloaded. Binds the model to a value by using the specified controller context, binding context, and model binders. (Defined by HttpActionContextExtensions.)
Public Extension Method GetMetadataProvider Retrieves the ModelMetadataProvider instance for a given HttpActionContext. (Defined by HttpActionContextExtensions.)
Public Extension Method GetValidatorProviders Retrieves the collection of registered ModelValidatorProvider instances. (Defined by HttpActionContextExtensions.)
Public Extension Method GetValidators Retrieves the collection of registered ModelValidator instances. (Defined by HttpActionContextExtensions.)
Public Extension Method TryBindStrongModel<TModel> Binds the model to the property by using the specified execution context and binding context. (Defined by HttpActionContextExtensions.)

Top

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

System.Web.Http.Controllers Namespace