Module io.inverno.mod.http.base
Class GenericQueryParameters
java.lang.Object
io.inverno.mod.http.base.internal.GenericQueryParameters
- All Implemented Interfaces:
QueryParameters
A generic QueryParameters implementation.
- Since:
- 1.6
- Author:
- Jeremy Kuhn
-
Constructor Summary
ConstructorsConstructorDescriptionGenericQueryParameters(Map<String, List<String>> queryParameters, ObjectConverter<String> parameterConverter) Creates query parameters. -
Method Summary
Modifier and TypeMethodDescriptionbooleanDetermines whether a parameter with the specified name is present.Returns the query parameter with the specified name.getAll()Returns all query parameters sent in the request.Returns all query parameters with the specified name.getNames()Returns the names of the query parameters sent in the request.
-
Constructor Details
-
Method Details
-
contains
Description copied from interface:QueryParametersDetermines whether a parameter with the specified name is present.
- Specified by:
containsin interfaceQueryParameters- Parameters:
name- a query parameter name- Returns:
- true if a parameter is present, false otherwise
-
getNames
Description copied from interface:QueryParametersReturns the names of the query parameters sent in the request.
- Specified by:
getNamesin interfaceQueryParameters- Returns:
- a list of header names
-
get
Description copied from interface:QueryParametersReturns the query parameter with the specified name.
If there are multiple parameters with the same name, this method returns the first one.
- Specified by:
getin interfaceQueryParameters- Parameters:
name- a query parameter name- Returns:
- an optional returning the parameter or an empty optional if there's no parameter with the specified name
-
getAll
Description copied from interface:QueryParametersReturns all query parameters with the specified name.
- Specified by:
getAllin interfaceQueryParameters- Parameters:
name- a query parameter name- Returns:
- a list of parameters or an empty list if there's no parameter with the specified name
-
getAll
Description copied from interface:QueryParametersReturns all query parameters sent in the request.
- Specified by:
getAllin interfaceQueryParameters- Returns:
- the parameters grouped by name
-