Export (0) Print
Expand All

HttpClientExtensions Class

Extension methods that aid in making formatted requests using HttpClient.

System.Object
  System.Net.Http.HttpClientExtensions

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

public static class HttpClientExtensions

  NameDescription
Public methodStatic memberPostAsJsonAsync<T>(HttpClient, String, T)Sends a POST request as an asynchronous operation, with a specified value serialized as JSON.
Public methodStatic memberPostAsJsonAsync<T>(HttpClient, String, T, CancellationToken)Sends a POST request as an asynchronous operation, with a specified value serialized as JSON. Includes a cancellation token to cancel the request.
Public methodStatic memberPostAsXmlAsync<T>(HttpClient, String, T)Sends a POST request as an asynchronous operation, with a specified value serialized as XML.
Public methodStatic memberPostAsXmlAsync<T>(HttpClient, String, T, CancellationToken)Sends a POST request as an asynchronous operation, with a specified value serialized as XML. Includes a cancellation token to cancel the request.
Public methodStatic memberPostAsync<T>(HttpClient, String, T, MediaTypeFormatter)Sends a POST request as an asynchronous operation, with a specified value serialized using the given formatter.
Public methodStatic memberPostAsync<T>(HttpClient, String, T, MediaTypeFormatter, String)Sends a POST request as an asynchronous operation, with a specified value serialized using the given formatter and media type string.
Public methodStatic memberPostAsync<T>(HttpClient, String, T, MediaTypeFormatter, CancellationToken)Sends a POST request as an asynchronous operation, with a specified value serialized using the given formatter. Includes a cancellation token to cancel the request.
Public methodStatic memberPostAsync<T>(HttpClient, String, T, MediaTypeFormatter, MediaTypeHeaderValue, CancellationToken)Sends a POST request as an asynchronous operation, with a specified value serialized using the given formatter and media type.
Public methodStatic memberPostAsync<T>(HttpClient, String, T, MediaTypeFormatter, String, CancellationToken)Sends a POST request as an asynchronous operation, with a specified value serialized using the given formatter and media type string. Includes a cancellation token to cancel the request.
Public methodStatic memberPutAsJsonAsync<T>(HttpClient, String, T)Sends a PUT request as an asynchronous operation, with a specified value serialized as JSON.
Public methodStatic memberPutAsJsonAsync<T>(HttpClient, String, T, CancellationToken)Sends a PUT request as an asynchronous operation, with a specified value serialized as JSON. Includes a cancellation token to cancel the request.
Public methodStatic memberPutAsXmlAsync<T>(HttpClient, String, T)Sends a PUT request as an asynchronous operation, with a specified value serialized as XML.
Public methodStatic memberPutAsXmlAsync<T>(HttpClient, String, T, CancellationToken)Sends a PUT request as an asynchronous operation, with a specified value serialized as XML. Includes a cancellation token to cancel the request.
Public methodStatic memberPutAsync<T>(HttpClient, String, T, MediaTypeFormatter)Sends a PUT request as an asynchronous operation, with a specified value serialized using the given formatter.
Public methodStatic memberPutAsync<T>(HttpClient, String, T, MediaTypeFormatter, String)Sends a PUT request as an asynchronous operation, with a specified value serialized using the given formatter and media type string.
Public methodStatic memberPutAsync<T>(HttpClient, String, T, MediaTypeFormatter, CancellationToken)Sends a PUT request as an asynchronous operation, with a specified value serialized using the given formatter and medai type string. Includes a cancellation token to cancel the request.
Public methodStatic memberPutAsync<T>(HttpClient, String, T, MediaTypeFormatter, MediaTypeHeaderValue, CancellationToken) Sends a PUT request as an asynchronous operation, with a specified value serialized using the given formatter and media type. Includes a cancellation token to cancel the request.
Public methodStatic memberPutAsync<T>(HttpClient, String, T, MediaTypeFormatter, String, CancellationToken)Sends a PUT request as an asynchronous operation, with a specified value serialized using the given formatter and media type string. Includes a cancellation token to cancel the request.
Top

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