Package play.core.cookie.encoding
Class ServerCookieDecoder
java.lang.Object
play.core.cookie.encoding.ServerCookieDecoder
A RFC6265 compliant cookie decoder to be used
server side.
Only name and value fields are expected, so old fields are not populated (path, domain, etc).
Old RFC2965 cookies are still supported, old fields will simply be ignored.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ServerCookieDecoderLax instance that doesn't validate name and valuestatic final ServerCookieDecoderStrict encoder that validates that name and value chars are in the valid scope defined in RFC6265 -
Method Summary
Modifier and TypeMethodDescriptionDecodes the specified Set-Cookie HTTP header value into aCookie.protected DefaultCookieinitCookie(String header, int nameBegin, int nameEnd, int valueBegin, int valueEnd)
-
Field Details
-
STRICT
Strict encoder that validates that name and value chars are in the valid scope defined in RFC6265 -
LAX
Lax instance that doesn't validate name and value
-
-
Method Details
-
decode
Decodes the specified Set-Cookie HTTP header value into aCookie.- Parameters:
header- the Set-Cookie header.- Returns:
- the decoded
Cookie
-
initCookie
protected DefaultCookie initCookie(String header, int nameBegin, int nameEnd, int valueBegin, int valueEnd)
-