public class NameValuePair
extends java.lang.Object
More information about this class is available from ostermiller.org.
| Constructor and Description |
|---|
NameValuePair(java.lang.String name,
java.lang.String value)
Construct a name value pair.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getName()
Get the name of the pair.
|
java.lang.String |
getValue()
Get the value of the pair.
|
java.lang.String |
toString()
Get the name and value as CGI parameters, URL Encoded to UTF-8.
|
java.lang.String |
toString(java.lang.String charset)
Get the name and value as CGI parameters, URL Encoded to the given encoding.
|
public NameValuePair(java.lang.String name,
java.lang.String value)
name - name of the pair.value - value of the pair.public java.lang.String getName()
public java.lang.String getValue()
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String toString(java.lang.String charset)
throws java.io.UnsupportedEncodingException
charset - Character set to use when URL Encoding.java.io.UnsupportedEncodingException - if the given character set is not supportedCopyright (c) 2001-2020 by Stephen Ostermiller