public class NameValuePairs extends Object
Create an instance using one of the static factory methods.
Modifier and Type | Method and Description |
---|---|
static NameValuePairs |
of(List<NameValuePair> pairs)
Returns a new instance that may have repeated names (for example, "number=1&number=2").
|
static NameValuePairs |
of(Map<String,?> map)
Returns a new instance using the entries of the given map in the map's iteration order.
|
static NameValuePairs |
of(NameValuePair... pairs)
Returns a new instance that may have repeated names (for example, "number=1&number=2").
|
static NameValuePairs |
ofPreEncoded(String preEncoded)
Returns an instance that uses the given string as-is.
|
String |
toString() |
public static NameValuePairs of(Map<String,?> map)
map
- Entries MUST NOT be URL-encoded; they will be URL-encoded automaticallypublic static NameValuePairs of(NameValuePair... pairs)
public static NameValuePairs of(List<NameValuePair> pairs)
public static NameValuePairs ofPreEncoded(String preEncoded)
preEncoded
- URL-encoded query string (without the "?" prefix).Copyright © 2024 Couchbase, Inc.. All rights reserved.