Top Description Fields Constructors Methods
reactor.netty.http

public Class Cookies

extends Object
Class Inheritance
Known Direct Subclasses
reactor.netty.http.server.ServerCookies
Imports
java.util.Collections, .HashMap, .HashSet, .List, .Map, .Objects, .Set, java.util.concurrent.atomic.AtomicIntegerFieldUpdater, io.netty.handler.codec.http.HttpHeaderNames, .HttpHeaders, io.netty.handler.codec.http.cookie.ClientCookieDecoder, .Cookie, .CookieDecoder, .ServerCookieDecoder

Store cookies for the http channel.
Since
0.6

Field Summary

Modifier and TypeField and Description
protected Map<CharSequence, Set<Cookie>>
pack-priv final CharSequence
pack-priv final CookieDecoder
pack-priv final boolean
pack-priv final HttpHeaders
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv volatile int
pack-priv static final AtomicIntegerFieldUpdater<Cookies>

Constructor Summary

AccessConstructor and Description
protected
Cookies(HttpHeaders nettyHeaders, CharSequence cookiesHeaderName, boolean isClientChannel, CookieDecoder decoder)

Method Summary

Modifier and TypeMethod and Description
protected List<String>
public Map<CharSequence, Set<Cookie>>

Returns:

the cached map of cookies
getCachedCookies
()

Wait for the cookies to become available, cache them and subsequently return the cached map of cookies.

protected final boolean
protected final boolean
protected final boolean
public static Cookies

Returns:

a new cookies holder from client response headers
newClientResponseHolder
(HttpHeaders
client response headers
headers
,
ClientCookieDecoder decoder)

Return a new cookies holder from client response headers.

public static Cookies

Returns:

a new cookies holder from server request headers
newServerRequestHolder
(HttpHeaders
server request headers
headers
,
ServerCookieDecoder decoder)

Deprecated as of 1.0.8.
Return a new cookies holder from server request headers.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

cachedCookiesback to summary
protected Map<CharSequence, Set<Cookie>> cachedCookies
cookiesHeaderNameback to summary
pack-priv final CharSequence cookiesHeaderName
decoderback to summary
pack-priv final CookieDecoder decoder
isClientChannelback to summary
pack-priv final boolean isClientChannel
nettyHeadersback to summary
pack-priv final HttpHeaders nettyHeaders
NOT_READback to summary
pack-priv static final int NOT_READ
READback to summary
pack-priv static final int READ
READINGback to summary
pack-priv static final int READING
stateback to summary
pack-priv volatile int state
STATEback to summary
pack-priv static final AtomicIntegerFieldUpdater<Cookies> STATE

Constructor Detail

Cookiesback to summary
protected Cookies(HttpHeaders nettyHeaders, CharSequence cookiesHeaderName, boolean isClientChannel, CookieDecoder decoder)

Method Detail

allCookieHeadersback to summary
protected List<String> allCookieHeaders()
getCachedCookiesback to summary
public Map<CharSequence, Set<Cookie>> getCachedCookies()

Wait for the cookies to become available, cache them and subsequently return the cached map of cookies.

Returns:Map<CharSequence, Set<Cookie>>

the cached map of cookies

hasReadCookiesback to summary
protected final boolean hasReadCookies()
markReadCookiesback to summary
protected final boolean markReadCookies()
markReadingCookiesback to summary
protected final boolean markReadingCookies()
newClientResponseHolderback to summary
public static Cookies newClientResponseHolder(HttpHeaders headers, ClientCookieDecoder decoder)

Return a new cookies holder from client response headers.

Parameters
headers:HttpHeaders

client response headers

Returns:Cookies

a new cookies holder from client response headers

newServerRequestHolderback to summary
public static Cookies newServerRequestHolder(HttpHeaders headers, ServerCookieDecoder decoder)

Deprecated

as of 1.0.8. Prefer reactor.netty.http.server.ServerCookies#newServerRequestHolder(HttpHeaders, ServerCookieDecoder). This method will be removed in version 1.2.0.

Return a new cookies holder from server request headers.

Parameters
headers:HttpHeaders

server request headers

Returns:Cookies

a new cookies holder from server request headers

Annotations
@Deprecated