Share via


CorsMessageHandler Class

 

Custom DelegatingHandler for handling CORS requests.

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

Inheritance Hierarchy

System.Object
  System.Net.Http.HttpMessageHandler
    System.Net.Http.DelegatingHandler
      System.Web.Http.Cors.CorsMessageHandler

Syntax

public class CorsMessageHandler : DelegatingHandler
public ref class CorsMessageHandler : DelegatingHandler
type CorsMessageHandler = 
    class
        inherit DelegatingHandler
    end
Public Class CorsMessageHandler
    Inherits DelegatingHandler

Constructors

Name Description
System_CAPS_pubmethod CorsMessageHandler(HttpConfiguration)

Initializes a new instance of the CorsMessageHandler class.

Properties

Name Description
System_CAPS_pubproperty InnerHandler

(Inherited from DelegatingHandler.)

Methods

Name Description
System_CAPS_pubmethod Dispose()

(Inherited from HttpMessageHandler.)

System_CAPS_protmethod Dispose(Boolean)

(Inherited from DelegatingHandler.)

System_CAPS_pubmethod Equals(Object)

(Inherited from Object.)

System_CAPS_protmethod Finalize()

(Inherited from Object.)

System_CAPS_pubmethod GetHashCode()

(Inherited from Object.)

System_CAPS_pubmethod GetType()

(Inherited from Object.)

System_CAPS_pubmethod HandleCorsPreflightRequestAsync(HttpRequestMessage, CorsRequestContext, CancellationToken)

Handles the preflight request specified by CORS.

System_CAPS_pubmethod HandleCorsRequestAsync(HttpRequestMessage, CorsRequestContext, CancellationToken)

Handles the actual CORS request.

System_CAPS_protmethod MemberwiseClone()

(Inherited from Object.)

System_CAPS_protmethod SendAsync(HttpRequestMessage, CancellationToken)

Sends an HTTP request to the inner handler to send to the server as an asynchronous operation.(Overrides DelegatingHandler.SendAsync(HttpRequestMessage, CancellationToken).)

System_CAPS_pubmethod ToString()

(Inherited from Object.)

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

System.Web.Http.Cors Namespace

Return to top