Class CookieCollection
- java.lang.Object
-
- org.apache.wicket.protocol.http.mock.CookieCollection
-
public class CookieCollection extends java.lang.Objectcookie collection utility- Author:
- mosmann
-
-
Constructor Summary
Constructors Constructor Description CookieCollection()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(javax.servlet.http.Cookie cookie)add cookie to collection if cookie is expired, it will be moved to expired cookie set overwrite existing cookie with new valuevoidaddAll(java.util.List<javax.servlet.http.Cookie> cookies)calls add on each cookievoidaddAll(javax.servlet.http.Cookie[] cookies)calls add on each cookiejava.util.List<javax.servlet.http.Cookie>allAsList()list of all cookies, expired or notjava.util.List<javax.servlet.http.Cookie>asList()list of non expired cookiesjava.util.List<javax.servlet.http.Cookie>expiredAsList()list of expired cookies
-
-
-
Method Detail
-
add
public void add(javax.servlet.http.Cookie cookie)
add cookie to collection if cookie is expired, it will be moved to expired cookie set overwrite existing cookie with new value- Parameters:
cookie- a cookie
-
addAll
public void addAll(javax.servlet.http.Cookie[] cookies)
calls add on each cookie- Parameters:
cookies- array of cookies
-
addAll
public void addAll(java.util.List<javax.servlet.http.Cookie> cookies)
calls add on each cookie- Parameters:
cookies- list of cookies
-
asList
public java.util.List<javax.servlet.http.Cookie> asList()
list of non expired cookies- Returns:
- as list
-
expiredAsList
public java.util.List<javax.servlet.http.Cookie> expiredAsList()
list of expired cookies- Returns:
- as list
-
allAsList
public java.util.List<javax.servlet.http.Cookie> allAsList()
list of all cookies, expired or not- Returns:
- as list
-
-