Package org.eclipse.jetty.http
Class HttpCookieStore.Empty
java.lang.Object
org.eclipse.jetty.http.HttpCookieStore.Empty
- All Implemented Interfaces:
HttpCookieStore
- Enclosing interface:
- HttpCookieStore
An implementation of HttpCookieStore
that does not store any cookie.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.jetty.http.HttpCookieStore
HttpCookieStore.Default, HttpCookieStore.Empty
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
add
(URI uri, HttpCookie cookie) Adds a cookie to this store, if possible.all()
boolean
clear()
Removes all the cookies from this store.Returns the cookies that match the givenURI
.boolean
remove
(URI uri, HttpCookie cookie) Removes the cookie associated with the givenURI
.
-
Constructor Details
-
Empty
public Empty()
-
-
Method Details
-
add
Description copied from interface:HttpCookieStore
Adds a cookie to this store, if possible.
The cookie may not be added for various reasons; for example, it may be already expired, or its domain attribute does not match that of the URI, etc.
The cookie is associated with the given
URI
, so that a call toHttpCookieStore.match(URI)
returns the cookie only if the URIs match.- Specified by:
add
in interfaceHttpCookieStore
- Parameters:
uri
- theURI
associated with the cookiecookie
- the cookie to add- Returns:
- whether the cookie has been added
-
all
- Specified by:
all
in interfaceHttpCookieStore
- Returns:
- all the cookies
-
match
Description copied from interface:HttpCookieStore
Returns the cookies that match the given
URI
.- Specified by:
match
in interfaceHttpCookieStore
- Parameters:
uri
- theURI
to match against- Returns:
- a list of cookies that match the given
URI
-
remove
Description copied from interface:HttpCookieStore
Removes the cookie associated with the given
URI
.- Specified by:
remove
in interfaceHttpCookieStore
- Parameters:
uri
- theURI
associated with the cookie to removecookie
- the cookie to remove- Returns:
- whether the cookie has been removed
-
clear
public boolean clear()Description copied from interface:HttpCookieStore
Removes all the cookies from this store.
- Specified by:
clear
in interfaceHttpCookieStore
- Returns:
- whether the store modified by this call
-