Package org.springframework.webflow.test
Class MockParameterMap
java.lang.Object
org.springframework.webflow.core.collection.LocalParameterMap
org.springframework.webflow.test.MockParameterMap
- All Implemented Interfaces:
Serializable
,org.springframework.binding.collection.MapAdaptable<String,
,Object> ParameterMap
A extension of parameter map that allows for mutation of parameters. Useful as a stub for testing.
- Author:
- Keith Donald
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionAdd a new parameter to this map.Add a new multi-valued parameter to this map.Add a new multi-valued multi-part file parameter to this map.Add a new multi-part file parameter to this map.Methods inherited from class org.springframework.webflow.core.collection.LocalParameterMap
asAttributeMap, asMap, contains, equals, get, get, get, get, getArray, getArray, getBoolean, getBoolean, getInteger, getInteger, getLong, getLong, getMapInternal, getMultipartFile, getNumber, getNumber, getRequired, getRequired, getRequiredArray, getRequiredArray, getRequiredBoolean, getRequiredInteger, getRequiredLong, getRequiredMultipartFile, getRequiredNumber, hashCode, initParameters, isEmpty, size, toString
-
Constructor Details
-
MockParameterMap
public MockParameterMap()Creates a new parameter map, initially empty.
-
-
Method Details
-
put
Add a new parameter to this map.- Parameters:
parameterName
- the parameter nameparameterValue
- the parameter value- Returns:
- this, to support call chaining
-
put
Add a new multi-valued parameter to this map.- Parameters:
parameterName
- the parameter nameparameterValues
- the parameter values- Returns:
- this, to support call chaining
-
put
public MockParameterMap put(String parameterName, org.springframework.web.multipart.MultipartFile parameterValues) Add a new multi-part file parameter to this map.- Parameters:
parameterName
- the parameter nameparameterValues
- the parameter values- Returns:
- this, to support call chaining
-
put
public MockParameterMap put(String parameterName, List<org.springframework.web.multipart.MultipartFile> parameterValues) Add a new multi-valued multi-part file parameter to this map.- Parameters:
parameterName
- the parameter nameparameterValues
- the parameter values- Returns:
- this, to support call chaining
-