HttpClient.GetInputStreamAsync(Uri) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Send a GET request to the specified Uri and return the response body as a stream in an asynchronous operation. For programming guidance for the HttpClient class, and code examples, see the HttpClient conceptual topic.
public:
virtual IAsyncOperationWithProgress<IInputStream ^, HttpProgress> ^ GetInputStreamAsync(Uri ^ uri) = GetInputStreamAsync;
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncOperationWithProgress<IInputStream, HttpProgress> GetInputStreamAsync(Uri const& uri);
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncOperationWithProgress<IInputStream,HttpProgress> GetInputStreamAsync(System.Uri uri);
function getInputStreamAsync(uri)
Public Function GetInputStreamAsync (uri As Uri) As IAsyncOperationWithProgress(Of IInputStream, HttpProgress)
Parameters
Returns
The object representing the asynchronous operation.
- Attributes
Remarks
This operation will not block. The returned IAsyncOperationWithProgress (of IInputStream and HttpProgress) completes after the whole response body is read. This method does not buffer the stream, so this method can support long streams of arbitrary length.
Below are the exceptions that this function throws.
E_INVALIDARG
The uri parameter was a null reference (Nothing in Visual Basic).