Top Description Fields Constructors Methods
org.springframework.web.bind

public Class UnsatisfiedServletRequestParameterException

extends ServletRequestBindingException
Class Inheritance
Annotations
@SuppressWarnings:serial
Imports
java.util.Iterator, .List, .Map, java.util.stream.Collectors, org.springframework.util.Assert, .ObjectUtils, .StringUtils

ServletRequestBindingException subclass that indicates an unsatisfied parameter condition, as typically expressed using an @RequestMapping annotation at the @Controller type level.
Author
Juergen Hoeller
Since
3.0
See Also
org.springframework.web.bind.annotation.RequestMapping#params()

Field Summary

Modifier and TypeField and Description
private final Map<String, String[]>
private final List<String[]>

Constructor Summary

AccessConstructor and Description
public
UnsatisfiedServletRequestParameterException(String[]
the parameter conditions that have been violated
paramConditions
,
Map<String, String[]>
the actual parameter Map associated with the ServletRequest
actualParams
)

Create a new UnsatisfiedServletRequestParameterException.

public
UnsatisfiedServletRequestParameterException(List<String[]>
all sets of parameter conditions that have been violated
paramConditions
,
Map<String, String[]>
the actual parameter Map associated with the ServletRequest
actualParams
)

Create a new UnsatisfiedServletRequestParameterException.

Method Summary

Modifier and TypeMethod and Description
public final Map<String, String[]>
getActualParams()

Return the actual parameter Map associated with the ServletRequest.

public String
getMessage()

Overrides java.lang.Throwable.getMessage.

Returns the detail message string of this throwable.
public final List<String[]>
getParamConditionGroups()

Return all parameter condition groups that have been violated.

public final String[]
getParamConditions()

Return the parameter conditions that have been violated or the first group in case of multiple groups.

private static List<String>
paramsToStringList(List<String[]> paramConditions)

private static String
Inherited from org.springframework.web.bind.ServletRequestBindingException:
getBodygetDetailMessageArgumentsgetDetailMessageCodegetStatusCode

Field Detail

actualParamsback to summary
private final Map<String, String[]> actualParams
paramConditionsback to summary
private final List<String[]> paramConditions

Constructor Detail

UnsatisfiedServletRequestParameterExceptionback to summary
public UnsatisfiedServletRequestParameterException(String[] paramConditions, Map<String, String[]> actualParams)

Create a new UnsatisfiedServletRequestParameterException.

Parameters
paramConditions:String[]

the parameter conditions that have been violated

actualParams:Map<String, String[]>

the actual parameter Map associated with the ServletRequest

UnsatisfiedServletRequestParameterExceptionback to summary
public UnsatisfiedServletRequestParameterException(List<String[]> paramConditions, Map<String, String[]> actualParams)

Create a new UnsatisfiedServletRequestParameterException.

Parameters
paramConditions:List<String[]>

all sets of parameter conditions that have been violated

actualParams:Map<String, String[]>

the actual parameter Map associated with the ServletRequest

Since
4.2

Method Detail

getActualParamsback to summary
public final Map<String, String[]> getActualParams()

Return the actual parameter Map associated with the ServletRequest.

See Also
jakarta.servlet.ServletRequest#getParameterMap()
getMessageback to summary
public String getMessage()

Overrides java.lang.Throwable.getMessage.

Doc from java.lang.Throwable.getMessage.

Returns the detail message string of this throwable.

Returns:String

the detail message string of this Throwable instance (which may be null).

Annotations
@Override
getParamConditionGroupsback to summary
public final List<String[]> getParamConditionGroups()

Return all parameter condition groups that have been violated.

Since
4.2
See Also
org.springframework.web.bind.annotation.RequestMapping#params()
getParamConditionsback to summary
public final String[] getParamConditions()

Return the parameter conditions that have been violated or the first group in case of multiple groups.

See Also
org.springframework.web.bind.annotation.RequestMapping#params()
paramsToStringListback to summary
private static List<String> paramsToStringList(List<String[]> paramConditions)
requestParameterMapToStringback to summary
private static String requestParameterMapToString(Map<String, String[]> actualParams)