HttpMessageInvoker Class

A specialty class that allows applications to call the SendAsync method on an Http handler chain.


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

type HttpMessageInvoker =  
        interface IDisposable 

The HttpMessageInvoker type exposes the following members.

Public methodHttpMessageInvoker(HttpMessageHandler)Initializes a new instance of the HttpMessageInvoker class with the specified message handler.
Public methodHttpMessageInvoker(HttpMessageHandler, Boolean)Initializes a new instance of the HttpMessageInvoker class with the specified message handler and value that indicates whether this instance is responsible for disposing the handler.

Public methodDispose()Releases the unmanaged resources and disposes of the managed resources used by the invoker.
Protected methodDispose(Boolean)Releases the unmanaged resources used by the invoker and optionally disposes of the managed resources.
Public methodEquals (Inherited from Object.)
Protected methodFinalize (Inherited from Object.)
Public methodGetHashCode (Inherited from Object.)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodSendAsyncSends an HTTP request with a cancellation token as an asynchronous operation.
Public methodToString (Inherited from Object.)

This class is the base type for HttpClient and other message originators.Most applications that are connecting to a web site will use one of the SendAsync methods on the HttpClient class.

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