@NotThreadSafe public class BasicClientCookie2 extends BasicClientCookie implements SetCookie2, Serializable
SetCookie2.COMMENT_ATTR, COMMENTURL_ATTR, DISCARD_ATTR, DOMAIN_ATTR, EXPIRES_ATTR, MAX_AGE_ATTR, PATH_ATTR, PORT_ATTR, SECURE_ATTR, VERSION_ATTR| Constructor and Description |
|---|
BasicClientCookie2(String name,
String value)
Default Constructor taking a name and a value.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
clone() |
String |
getCommentURL()
Returns null.
|
int[] |
getPorts()
Returns null.
|
boolean |
isExpired(Date date)
Returns true if this cookie has expired.
|
boolean |
isPersistent()
Returns false if the cookie should be discarded at the end
of the "session"; true otherwise.
|
void |
setCommentURL(String commentURL)
If a user agent (web browser) presents this cookie to a user, the
cookie's purpose will be described by the information at this URL.
|
void |
setDiscard(boolean discard)
Set the Discard attribute.
|
void |
setPorts(int[] ports)
Sets the Port attribute.
|
containsAttribute, getAttribute, getComment, getDomain, getExpiryDate, getName, getPath, getValue, getVersion, isSecure, setAttribute, setComment, setDomain, setExpiryDate, setPath, setSecure, setValue, setVersion, toStringequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitsetComment, setDomain, setExpiryDate, setPath, setSecure, setValue, setVersiongetComment, getDomain, getExpiryDate, getName, getPath, getValue, getVersion, isSecurepublic int[] getPorts()
BasicClientCookiegetPorts in interface CookiegetPorts in class BasicClientCookiepublic void setPorts(int[] ports)
SetCookie2setPorts in interface SetCookie2public String getCommentURL()
BasicClientCookiegetCommentURL in interface CookiegetCommentURL in class BasicClientCookiepublic void setCommentURL(String commentURL)
SetCookie2setCommentURL in interface SetCookie2public void setDiscard(boolean discard)
SetCookie2setDiscard in interface SetCookie2Cookie.isPersistent()public boolean isPersistent()
BasicClientCookieisPersistent in interface CookieisPersistent in class BasicClientCookiepublic boolean isExpired(Date date)
BasicClientCookieisExpired in interface CookieisExpired in class BasicClientCookiedate - Current timepublic Object clone() throws CloneNotSupportedException
clone in class BasicClientCookieCloneNotSupportedExceptionCopyright © 1999–2013 The Apache Software Foundation. All rights reserved.