5

到目前为止我一直使用:

HttpWebRequest request = (HttpWebRequest)WebRequest.Create(targetUri);

do the request
.................
request.ServicePoint. 

现在我想使用 .net 4.5 中的新 HttpClient ,但我不知道如何访问 ServicePoint 属性。

任何想法如何使用 HttpClient 访问 ServicePoint?

4

1 回答 1

3

我相信你将不得不使用ServicePointManager来做你想做的事。就像是;

ServicePointManager.FindServicePoint(targetUri)
于 2013-10-04T07:41:49.327 回答