public class CookieCutter
extends java.lang.Object
Optimized stateful Cookie
header parser.
Does not support Set-Cookie
header parsing.
Cookies fields are added with the addCookieField(String)
method and
parsed on the next subsequent call to getCookies()
.
If the added fields are identical to those last added (as strings), then the cookies are not re parsed.
Modifier and Type | Field and Description |
---|---|
private CookieCompliance |
_compliance |
private javax.servlet.http.Cookie[] |
_cookies |
private java.util.List<java.lang.String> |
_fieldList |
(package private) int |
_fields |
private javax.servlet.http.Cookie[] |
_lastCookies |
private static Logger |
LOG |
Constructor and Description |
---|
CookieCutter() |
CookieCutter(CookieCompliance compliance) |
Modifier and Type | Method and Description |
---|---|
void |
addCookieField(java.lang.String f) |
javax.servlet.http.Cookie[] |
getCookies() |
protected void |
parseFields() |
void |
reset() |
void |
setCookies(javax.servlet.http.Cookie[] cookies) |
private static final Logger LOG
private final CookieCompliance _compliance
private javax.servlet.http.Cookie[] _cookies
private javax.servlet.http.Cookie[] _lastCookies
private final java.util.List<java.lang.String> _fieldList
int _fields
public CookieCutter()
public CookieCutter(CookieCompliance compliance)