开发者

Java's equivalent of .Net's WebClient

What is the equivalent method or code construction to what WebClient is in .Net? Here is the description of it:

Provides common methods for sending data to and receiving data from a开发者_如何学编程 resource identified by a URI.

Basically I need to know how would I put parameters to the request, just like they do in .Net:

WebClient client = this.WebClient();
client.QueryString.Add("param1", "name");
client.QueryString.Add("param2", "lastname");


This concept is used with REST web services. The resources can be accessed through a URI. Here is a helpful link: Rest web services - GO TO SECTION 5.5(Create a client)

SECTION 5.5

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜