Package io.micronaut.http.netty.cookies
Class NettyCookies
java.lang.Object
io.micronaut.http.netty.cookies.NettyCookies
- All Implemented Interfaces:
ConversionServiceProvider
,ConvertibleValues<Cookie>
,ValueResolver<CharSequence>
,Cookies
,Iterable<Map.Entry<String,
Cookie>>
Delegates to
Cookie
.- Since:
- 1.0
- Author:
- Graeme Rocher
-
Field Summary
Fields inherited from interface io.micronaut.core.convert.value.ConvertibleValues
EMPTY
-
Constructor Summary
ConstructorDescriptionNettyCookies
(io.netty.handler.codec.http.HttpHeaders nettyHeaders, ConversionService conversionService) NettyCookies
(String path, io.netty.handler.codec.http.HttpHeaders nettyHeaders, ConversionService conversionService) -
Method Summary
Modifier and TypeMethodDescriptionfindCookie
(CharSequence name) Find aCookie
for the given name.<T> Optional<T>
get
(CharSequence name, ArgumentConversionContext<T> conversionContext) Resolve the given property for the given name.<T> Optional<T>
get
(CharSequence name, Class<T> requiredType) Resolve the given property for the given name.getAll()
Provides the conversion service.values()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.core.convert.value.ConvertibleValues
asMap, asMap, asProperties, contains, forEach, getValue, getValueType, isEmpty, iterator, subMap, subMap, subMap
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface io.micronaut.core.value.ValueResolver
get, get
-
Constructor Details
-
NettyCookies
public NettyCookies(String path, io.netty.handler.codec.http.HttpHeaders nettyHeaders, ConversionService conversionService) - Parameters:
path
- The pathnettyHeaders
- The Netty HTTP headersconversionService
- The conversion service
-
NettyCookies
public NettyCookies(io.netty.handler.codec.http.HttpHeaders nettyHeaders, ConversionService conversionService) - Parameters:
nettyHeaders
- The Netty HTTP headersconversionService
- The conversion service
-
-
Method Details
-
getAll
-
findCookie
Description copied from interface:Cookies
Find aCookie
for the given name.- Specified by:
findCookie
in interfaceCookies
- Parameters:
name
- The cookie- Returns:
- An
Optional
cookie
-
get
Description copied from interface:ValueResolver
Resolve the given property for the given name.- Specified by:
get
in interfaceValueResolver<CharSequence>
- Type Parameters:
T
- The concrete type- Parameters:
name
- The namerequiredType
- The required type- Returns:
- An optional containing the property value if it exists and is able to be converted
-
get
Description copied from interface:ValueResolver
Resolve the given property for the given name.- Specified by:
get
in interfaceValueResolver<CharSequence>
- Type Parameters:
T
- The concrete type- Parameters:
name
- The nameconversionContext
- The conversion context- Returns:
- An optional containing the property value if it exists and is able to be converted
-
values
- Specified by:
values
in interfaceConvertibleValues<Cookie>
- Returns:
- The values
-
getConversionService
Description copied from interface:ConversionServiceProvider
Provides the conversion service.- Specified by:
getConversionService
in interfaceConversionServiceProvider
- Specified by:
getConversionService
in interfaceConvertibleValues<Cookie>
- Returns:
- the conversion service
-