Język

IManagedClientConnectionExtensions.OpenAsync Method

Definition

Runs Open(HttpRoute, IHttpContext, IHttpParams) on a thread pool thread to open the connection along the specified route.

public static System.Threading.Tasks.Task OpenAsync(this Org.Apache.Http.Conn.IManagedClientConnection self, Org.Apache.Http.Conn.Routing.HttpRoute? route, Org.Apache.Http.Protocol.IHttpContext? context, Org.Apache.Http.Params.IHttpParams? params);
static member OpenAsync : Org.Apache.Http.Conn.IManagedClientConnection * Org.Apache.Http.Conn.Routing.HttpRoute * Org.Apache.Http.Protocol.IHttpContext * Org.Apache.Http.Params.IHttpParams -> System.Threading.Tasks.Task

Parameters

self
IManagedClientConnection

The managed connection to open.

route
HttpRoute

The route for the connection. The connection opens to the first proxy, if present, or directly to the target host.

context
IHttpContext

The context for opening the connection.

params
IHttpParams

The HTTP parameters for opening the connection.

Returns

A task that completes when the synchronous connection method completes. If that method throws an exception, the task is faulted with that exception.

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to