Package io.micronaut.http.simple
Class SimpleHttpParameters
java.lang.Object
io.micronaut.http.simple.SimpleHttpParameters
- All Implemented Interfaces:
io.micronaut.core.convert.ConversionServiceAware,io.micronaut.core.convert.ConversionServiceProvider,io.micronaut.core.convert.value.ConvertibleMultiValues<String>,io.micronaut.core.convert.value.ConvertibleValues<List<String>>,io.micronaut.core.value.ValueResolver<CharSequence>,HttpParameters,MutableHttpParameters,Iterable<Map.Entry<String,List<String>>>
Simple implementation of
MutableHttpParameters.- Since:
- 1.0
-
Field Summary
Fields inherited from interface io.micronaut.core.convert.value.ConvertibleValues
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionSimpleHttpParameters(io.micronaut.core.convert.ConversionService conversionService) SimpleHttpParameters(Map<CharSequence, List<String>> values, io.micronaut.core.convert.ConversionService conversionService) -
Method Summary
Modifier and TypeMethodDescriptionadd(CharSequence name, List<CharSequence> values) Adds a new http parameter.get(CharSequence name) <T> Optional<T>get(CharSequence name, io.micronaut.core.convert.ArgumentConversionContext<T> conversionContext) getAll(CharSequence name) names()voidsetConversionService(io.micronaut.core.convert.ConversionService conversionService) values()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.micronaut.core.convert.value.ConvertibleMultiValues
forEach, forEachValue, getFirst, getFirst, getFirst, getFirst, getFirst, isEmpty, iteratorMethods inherited from interface io.micronaut.core.convert.value.ConvertibleValues
asMap, asMap, asProperties, contains, getConversionService, getValue, getValueType, subMap, subMap, subMapMethods inherited from interface java.lang.Iterable
forEach, spliteratorMethods inherited from interface io.micronaut.http.MutableHttpParameters
addMethods inherited from interface io.micronaut.core.value.ValueResolver
get, get, get
-
Constructor Details
-
SimpleHttpParameters
public SimpleHttpParameters(Map<CharSequence, List<String>> values, io.micronaut.core.convert.ConversionService conversionService) - Parameters:
values- The parameter valuesconversionService- The conversion service
-
SimpleHttpParameters
public SimpleHttpParameters(io.micronaut.core.convert.ConversionService conversionService) - Parameters:
conversionService- The conversion service
-
-
Method Details
-
names
-
values
-
getAll
- Specified by:
getAllin interfaceio.micronaut.core.convert.value.ConvertibleMultiValues<String>
-
get
- Specified by:
getin interfaceio.micronaut.core.convert.value.ConvertibleMultiValues<String>
-
get
public <T> Optional<T> get(CharSequence name, io.micronaut.core.convert.ArgumentConversionContext<T> conversionContext) - Specified by:
getin interfaceio.micronaut.core.value.ValueResolver<CharSequence>
-
add
Description copied from interface:MutableHttpParametersAdds a new http parameter.- Specified by:
addin interfaceMutableHttpParameters- Parameters:
name- the name of the parametervalues- the values of the parameter- Returns:
- self
-
setConversionService
public void setConversionService(io.micronaut.core.convert.ConversionService conversionService) - Specified by:
setConversionServicein interfaceio.micronaut.core.convert.ConversionServiceAware
-