public abstract class BaseMutablePortletParameters<T extends MutablePortletParameters> extends BasePortletParametersImpl<T> implements LiferayMutablePortletParameters
Constructor and Description |
---|
BaseMutablePortletParameters(Map<String,String[]> parameterMap,
Function<Map<String,String[]>,T> mutablePortletParametersCreator) |
Modifier and Type | Method and Description |
---|---|
MutablePortletParameters |
add(PortletParameters portletParameters) |
void |
clear() |
boolean |
isMutated()
Returns
true if the state of the portlet parameters has
changed. |
boolean |
removeParameter(String name) |
MutablePortletParameters |
set(PortletParameters portletParameters) |
String |
setValue(String name,
String value) |
String |
setValue(String name,
String value,
boolean append)
Sets the parameter value.
|
String[] |
setValues(String name,
String... values) |
String[] |
setValues(String name,
String[] values,
boolean append)
Sets the parameter values.
|
clone, deepCopyMap, getNames, getParameterMap, getValue, getValues, isEmpty, size
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getNames
public BaseMutablePortletParameters(Map<String,String[]> parameterMap, Function<Map<String,String[]>,T> mutablePortletParametersCreator)
public MutablePortletParameters add(PortletParameters portletParameters)
add
in interface MutablePortletParameters
public void clear()
clear
in interface MutablePortletParameters
public boolean isMutated()
LiferayMutablePortletParameters
true
if the state of the portlet parameters has
changed.isMutated
in interface LiferayMutablePortletParameters
true
if the state has changed; false
otherwisepublic boolean removeParameter(String name)
removeParameter
in interface MutablePortletParameters
public MutablePortletParameters set(PortletParameters portletParameters)
set
in interface MutablePortletParameters
public String setValue(String name, String value)
setValue
in interface MutablePortletParameters
public String setValue(String name, String value, boolean append)
LiferayMutablePortletParameters
IllegalArgumentException
is
thrown if the name is null
.setValue
in interface LiferayMutablePortletParameters
name
- the parameter's namevalue
- the parameter's value. If null
, the parameter
is removed.append
- whether the new value is appended to any existing values
for the parameter. If this is false
, any existing
values are overwritten with the new value.public String[] setValues(String name, String... values)
setValues
in interface MutablePortletParameters
public String[] setValues(String name, String[] values, boolean append)
LiferayMutablePortletParameters
IllegalArgumentException
is
thrown if the name is null
.setValues
in interface LiferayMutablePortletParameters
name
- the parameter's namevalues
- the parameter's values. If null
, the
parameter is removed.append
- whether the new values are appended to any existing values
for the parameter. If this is false
, any existing
values are overwritten with the new values.