public class ParametersStateString extends StateString implements Serializable
EMPTY, JBPNS_PREFIX, OPAQUE, SERIALIZED| Modifier | Constructor and Description |
|---|---|
protected |
ParametersStateString()
Creates an empty parameter set.
|
protected |
ParametersStateString(DataInputStream in) |
protected |
ParametersStateString(String opaqueValue) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Clear all the parameters.
|
static ParametersStateString |
create() |
static ParametersStateString |
create(Map<String,String[]> parameters) |
static ParametersStateString |
create(StateString stateString)
Create a parameters state string.
|
boolean |
equals(Object obj) |
Map<String,String[]> |
getParameters()
Return the underlying parameter object.
|
int |
getSize()
Return the size.
|
String |
getStringValue()
Retrieves the opaque version associated with this navigational state.
|
String |
getValue(String name)
Return the parameter value or null if it does not exist.
|
String[] |
getValues(String name)
Return the parameter values or null if it does not exist.
|
int |
hashCode() |
void |
remove(String name)
Remove a parameter.
|
void |
replace(Map<String,String[]> map)
Replace all the parameters.
|
void |
setValue(String name,
String value)
Set the a parameter value.
|
void |
setValues(String name,
String[] values)
Set the parameter values.
|
String |
toString() |
void |
writeTo(DataOutputStream out) |
create, create, decodeOpaqueValue, encodeAsOpaqueValueprotected ParametersStateString(DataInputStream in) throws IOException
IOExceptionprotected ParametersStateString(String opaqueValue)
protected ParametersStateString()
public static ParametersStateString create()
public static ParametersStateString create(Map<String,String[]> parameters)
public static ParametersStateString create(StateString stateString) throws IllegalArgumentException
ParametersStateString or that it is the string encoded value of a
ParametersStateString.stateString - the state stringIllegalArgumentException - if the state string is opaque and does not represent parameterspublic String getValue(String name) throws IllegalArgumentException
name - the parameter nameIllegalArgumentException - if the name is nullpublic String[] getValues(String name) throws IllegalArgumentException
name - the value to getIllegalArgumentException - if the name is nullpublic void clear()
public void replace(Map<String,String[]> map)
map - the map to replaceIllegalArgumentException - if the map is not validpublic void setValue(String name, String value)
name - the parameter namevalue - the parameter valueIllegalArgumentException - if the name or the value is nullpublic void setValues(String name, String[] values)
name - the parameter namevalues - the parameter valuesIllegalArgumentException - if the name is nullpublic void remove(String name)
name - the parameter nameIllegalArgumentException - if the name is nullpublic int getSize()
public Map<String,String[]> getParameters()
public String getStringValue()
getStringValue in class StateStringpublic void writeTo(DataOutputStream out) throws IOException
writeTo in class StateStringIOExceptionCopyright © 2003-2018 GateIn. All Rights Reserved.