public class Form extends Series<Parameter>
EMPTY_VALUE
Constructor and Description |
---|
Form()
Empty constructor.
|
Form(int initialCapacity)
Constructor.
|
Form(List<Parameter> delegate)
Constructor.
|
Form(Representation webForm)
Constructor.
|
Form(Representation webForm,
boolean decode)
Constructor.
|
Form(String queryString)
Constructor.
|
Form(String queryString,
boolean decode)
Constructor.
|
Form(String parametersString,
char separator)
Constructor.
|
Form(String queryString,
CharacterSet characterSet)
Constructor.
|
Form(String queryString,
CharacterSet characterSet,
boolean decode)
Constructor.
|
Form(String parametersString,
CharacterSet characterSet,
char separator)
Constructor.
|
Form(String parametersString,
CharacterSet characterSet,
char separator,
boolean decode)
Constructor.
|
Form(String parametersString,
char separator,
boolean decode)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Parameter |
createEntry(String name,
String value)
Creates a new entry.
|
String |
encode()
Encodes the form using the standard URI encoding mechanism and the UTF-8
character set.
|
String |
encode(CharacterSet characterSet)
URL encodes the form.
|
String |
encode(CharacterSet characterSet,
char separator)
URL encodes the form.
|
String |
getMatrixString()
Formats the form as a matrix path string.
|
String |
getMatrixString(CharacterSet characterSet)
Formats the form as a query string.
|
String |
getQueryString()
Formats the form as a query string.
|
String |
getQueryString(CharacterSet characterSet)
Formats the form as a query string.
|
Representation |
getWebRepresentation()
Returns the form as a Web representation
(MediaType.APPLICATION_WWW_FORM).
|
Representation |
getWebRepresentation(CharacterSet characterSet)
Returns the form as a Web representation
(MediaType.APPLICATION_WWW_FORM).
|
add, copyTo, getFirst, getFirst, getFirstValue, getFirstValue, getFirstValue, getFirstValue, getNames, getValues, getValues, getValuesArray, getValuesArray, getValuesArray, getValuesArray, getValuesMap, removeAll, removeAll, removeFirst, removeFirst, set, set, subList, subList, subList, unmodifiableSeries
add, add, addAll, addAll, clear, contains, containsAll, equals, get, getDelegate, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, toArray, toArray, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
replaceAll, sort, spliterator
parallelStream, removeIf, stream
public Form()
public Form(int initialCapacity)
initialCapacity
- The initial list capacity.public Form(Representation webForm)
webForm
- The URL encoded Web form.IOException
public Form(Representation webForm, boolean decode)
webForm
- The URL encoded Web form.IOException
public Form(String queryString)
queryString
- The Web form parameters as a string.IOException
public Form(String queryString, boolean decode)
queryString
- The Web form parameters as a string.decode
- Indicates if the names and values should be automatically
decoded.IOException
public Form(String parametersString, char separator)
parametersString
- The parameters string to parse.separator
- The separator character to append between parameters.IOException
public Form(String parametersString, char separator, boolean decode)
parametersString
- The parameters string to parse.separator
- The separator character to append between parameters.decode
- Indicates if the names and values should be automatically
decoded.IOException
public Form(String queryString, CharacterSet characterSet)
queryString
- The Web form parameters as a string.characterSet
- The supported character encoding.IOException
public Form(String queryString, CharacterSet characterSet, boolean decode)
queryString
- The Web form parameters as a string.characterSet
- The supported character encoding.decode
- Indicates if the names and values should be automatically
decoded.IOException
public Form(String parametersString, CharacterSet characterSet, char separator)
parametersString
- The parameters string to parse.characterSet
- The supported character encoding.separator
- The separator character to append between parameters.IOException
public Form(String parametersString, CharacterSet characterSet, char separator, boolean decode)
parametersString
- The parameters string to parse.characterSet
- The supported character encoding.separator
- The separator character to append between parameters.decode
- Indicates if the names and values should be automatically
decoded.IOException
public Parameter createEntry(String name, String value)
Series
createEntry
in class Series<Parameter>
name
- The name of the entry.value
- The value of the entry.public String encode() throws IOException
IOException
public String encode(CharacterSet characterSet) throws IOException
characterSet
- The supported character encoding.IOException
public String encode(CharacterSet characterSet, char separator) throws IOException
characterSet
- The supported character encoding.separator
- The separator character to append between parameters.IOException
public String getMatrixString()
public String getMatrixString(CharacterSet characterSet)
characterSet
- The supported character encoding.public String getQueryString()
public String getQueryString(CharacterSet characterSet)
characterSet
- The supported character encoding.public Representation getWebRepresentation()
public Representation getWebRepresentation(CharacterSet characterSet)
characterSet
- The supported character encoding.Copyright © 2005–2015. All rights reserved.