Package io.netty.handler.codec.http
Class ClientCookieEncoder
java.lang.Object
io.netty.handler.codec.http.ClientCookieEncoder
Deprecated.
A RFC6265 compliant cookie encoder to be used client side,
so only name=value pairs are sent.
User-Agents are not supposed to interpret cookies, so, if present,
will be used.
Otherwise,
invalid @link
Cookie#rawValue()
Cookie.value() will be used unquoted.
Note that multiple cookies are supposed to be sent at once in a single "Cookie" header.
// ExampleHttpRequestreq = ...; res.setHeader("Cookie",ClientCookieEncoder.encode("JSESSIONID", "1234"));
- See Also:
-
Method Summary
-
Method Details
-
encode
Deprecated.Encodes the specified cookie into a Cookie header value.- Parameters:
name- the cookie namevalue- the cookie value- Returns:
- a Rfc6265 style Cookie header value
-
encode
Deprecated.Encodes the specified cookie into a Cookie header value.- Parameters:
cookie- the specified cookie- Returns:
- a Rfc6265 style Cookie header value
-
encode
Deprecated.Encodes the specified cookies into a single Cookie header value.- Parameters:
cookies- some cookies- Returns:
- a Rfc6265 style Cookie header value, null if no cookies are passed.
-
encode
Deprecated.Encodes the specified cookies into a single Cookie header value.- Parameters:
cookies- some cookies- Returns:
- a Rfc6265 style Cookie header value, null if no cookies are passed.
-