HttpServer Class

 

Defines an implementation of an HttpMessageHandler which dispatches an incoming HttpRequestMessage and creates an HttpResponseMessage as a result.

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

Inheritance Hierarchy

System.Object
  System.Net.Http.HttpMessageHandler
    System.Net.Http.DelegatingHandler
      System.Web.Http.HttpServer
        System.Web.Http.SelfHost.HttpSelfHostServer

Syntax

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

Constructors

Name Description
System_CAPS_pubmethod HttpServer()

Initializes a new instance of the HttpServer class, using the default configuration and dispatcher.

System_CAPS_pubmethod HttpServer(HttpConfiguration)

Initializes a new instance of the HttpServer class with a specified configuration.

System_CAPS_pubmethod HttpServer(HttpConfiguration, HttpMessageHandler)

Initializes a new instance of the HttpServer class with a specified configuration and dispatcher.

System_CAPS_pubmethod HttpServer(HttpMessageHandler)

Initializes a new instance of the HttpServer class with a specified dispatcher.

Properties

Name Description
System_CAPS_pubproperty Configuration

Gets the HttpConfiguration used to configure this instance.

System_CAPS_pubproperty Dispatcher

Gets the HTTP dispatcher that handles incoming requests.

System_CAPS_pubproperty InnerHandler

(Inherited from DelegatingHandler.)

Methods

Name Description
System_CAPS_pubmethod Dispose()

(Inherited from HttpMessageHandler.)

System_CAPS_protmethod Dispose(Boolean)

Releases the unmanaged resources that are used by the object and, optionally, releases the managed resources.(Overrides DelegatingHandler.Dispose(Boolean).)

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_protmethod Initialize()

Prepares the server for operation.

System_CAPS_protmethod MemberwiseClone()

(Inherited from Object.)

System_CAPS_protmethod SendAsync(HttpRequestMessage, CancellationToken)

Dispatches an incoming HttpRequestMessage.(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 Namespace

Return to top