@NotThreadSafe public class BasicClientCookie2 extends BasicClientCookie implements SetCookie2
SetCookie2.COMMENT_ATTR, COMMENTURL_ATTR, DISCARD_ATTR, DOMAIN_ATTR, EXPIRES_ATTR, MAX_AGE_ATTR, PATH_ATTR, PORT_ATTR, SECURE_ATTR, VERSION_ATTR| 构造器和说明 |
|---|
BasicClientCookie2(java.lang.String name,
java.lang.String value)
Default Constructor taking a name and a value.
|
| 限定符和类型 | 方法和说明 |
|---|---|
java.lang.Object |
clone() |
java.lang.String |
getCommentURL()
Returns null.
|
int[] |
getPorts()
Returns null.
|
boolean |
isExpired(java.util.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(java.lang.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, toStringsetComment, setDomain, setExpiryDate, setPath, setSecure, setValue, setVersiongetComment, getDomain, getExpiryDate, getName, getPath, getValue, getVersion, isSecurepublic BasicClientCookie2(java.lang.String name,
java.lang.String value)
name - The name.value - The value.public int[] getPorts()
BasicClientCookiegetPorts 在接口中 CookiegetPorts 在类中 BasicClientCookiepublic void setPorts(int[] ports)
SetCookie2setPorts 在接口中 SetCookie2public java.lang.String getCommentURL()
BasicClientCookiegetCommentURL 在接口中 CookiegetCommentURL 在类中 BasicClientCookiepublic void setCommentURL(java.lang.String commentURL)
SetCookie2setCommentURL 在接口中 SetCookie2public void setDiscard(boolean discard)
SetCookie2setDiscard 在接口中 SetCookie2Cookie.isPersistent()public boolean isPersistent()
BasicClientCookieisPersistent 在接口中 CookieisPersistent 在类中 BasicClientCookiepublic boolean isExpired(java.util.Date date)
BasicClientCookieisExpired 在接口中 CookieisExpired 在类中 BasicClientCookiedate - Current timepublic java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone 在类中 BasicClientCookiejava.lang.CloneNotSupportedException