mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-12-20 17:47:57 +01:00
Update hoxt documentation to use List instead of Set for headers.
This commit is contained in:
parent
e20c17050e
commit
3ff1ab6e1f
1 changed files with 5 additions and 5 deletions
|
@ -73,11 +73,11 @@ HttpOverXmppReq req = new HttpOverXmppReq(HttpMethod.POST, "/mailbox");
|
||||||
req.setVersion("1.1");
|
req.setVersion("1.1");
|
||||||
|
|
||||||
// prepare headers
|
// prepare headers
|
||||||
Set<Header> set = new HashSet<Header>();
|
List<Header> list = new ArrayList<Header>();
|
||||||
set.add(new Header("Host", "juliet.capulet.com"));
|
list.add(new Header("Host", "juliet.capulet.com"));
|
||||||
set.add(new Header("Content-Type", "application/x-www-form- urlencoded"));
|
list.add(new Header("Content-Type", "application/x-www-form- urlencoded"));
|
||||||
set.add(new Header("Content-Length", Integer.toString(urlEncodedMessage.length())));
|
list.add(new Header("Content-Length", Integer.toString(urlEncodedMessage.length())));
|
||||||
req.setHeaders(new HeadersExtension(set));
|
req.setHeaders(new HeadersExtension(list));
|
||||||
|
|
||||||
// provide body or request (not mandatory, - empty body is used for GET)
|
// provide body or request (not mandatory, - empty body is used for GET)
|
||||||
AbstractHttpOverXmpp.Text child = new AbstractHttpOverXmpp.Text(urlEncodedMessage);
|
AbstractHttpOverXmpp.Text child = new AbstractHttpOverXmpp.Text(urlEncodedMessage);
|
||||||
|
|
Loading…
Reference in a new issue