Freigeben über


HttpServer Class

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

Inheritance Hierarchy

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

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

Syntax

'Declaration
Public Class HttpServer _
    Inherits DelegatingHandler
'Usage
Dim instance As HttpServer
public class HttpServer : DelegatingHandler
public ref class HttpServer : public DelegatingHandler
type HttpServer =  
    class
        inherit DelegatingHandler
    end
public class HttpServer extends DelegatingHandler

The HttpServer type exposes the following members.

Constructors

  Name Description
Public method HttpServer() Initializes a new instance of the HttpServer class, using the default configuration and dispatcher.
Public method HttpServer(HttpMessageHandler) Initializes a new instance of the HttpServer class with a specified dispatcher.
Public method HttpServer(HttpConfiguration) Initializes a new instance of the HttpServer class with a specified configuration.
Public method HttpServer(HttpConfiguration, HttpMessageHandler) Initializes a new instance of the HttpServer class with a specified configuration and dispatcher.

Top

Properties

  Name Description
Public property Configuration Gets the HttpConfiguration used to configure this instance.
Public property Dispatcher Gets the HTTP dispatcher that handles incoming requests.
Public property InnerHandler (Inherited from DelegatingHandler.)

Top

Methods

  Name Description
Public method Dispose() (Inherited from HttpMessageHandler.)
Protected method Dispose(Boolean) Releases the unmanaged resources that are used by the object and, optionally, releases the managed resources. (Overrides DelegatingHandlerDispose(Boolean).)
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 Initialize Prepares the server for operation.
Protected method MemberwiseClone (Inherited from Object.)
Protected method SendAsync Dispatches an incoming HttpRequestMessage. (Overrides DelegatingHandlerSendAsync(HttpRequestMessage, CancellationToken).)
Public method ToString (Inherited from Object.)

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 Namespace