Constructor and Description |
---|
DefaultCookie(String name,
String value)
Creates a new cookie with the specified name and value.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Cookie c) |
boolean |
equals(Object o) |
String |
getComment()
Returns the comment of this cookie.
|
String |
getCommentUrl()
Returns the comment URL of this cookie.
|
String |
getDomain()
Returns the domain of this cookie.
|
int |
getMaxAge()
Returns the max age of this cookie in seconds.
|
String |
getName()
Returns the name of this cookie.
|
String |
getPath()
Returns the path of this cookie.
|
Set<Integer> |
getPorts()
Returns the ports of this cookie.
|
String |
getValue()
Returns the value of this cookie.
|
int |
getVersion()
Returns the version of this cookie.
|
int |
hashCode() |
boolean |
isDiscard()
Returns the discard flag of this cookie.
|
boolean |
isHttpOnly()
Returns if this cookie cannot be accessed through client side script.
|
boolean |
isSecure()
Returns the secure flag of this cookie.
|
void |
setComment(String comment)
Sets the comment of this cookie.
|
void |
setCommentUrl(String commentUrl)
Sets the comment URL of this cookie.
|
void |
setDiscard(boolean discard)
Sets the discard flag of this cookie.
|
void |
setDomain(String domain)
Sets the domain of this cookie.
|
void |
setHttpOnly(boolean httpOnly)
Sets if this cookie cannot be accessed through client side script.
|
void |
setMaxAge(int maxAge)
Sets the max age of this cookie in seconds.
|
void |
setPath(String path)
Sets the path of this cookie.
|
void |
setPorts(int... ports)
Sets the ports of this cookie.
|
void |
setPorts(Iterable<Integer> ports)
Sets the ports of this cookie.
|
void |
setSecure(boolean secure)
Sets the secure flag of this cookie.
|
void |
setValue(String value)
Sets the value of this cookie.
|
void |
setVersion(int version)
Sets the version of this cookie.
|
String |
toString() |
public String getName()
Cookie
public String getValue()
Cookie
public void setValue(String value)
Cookie
public String getDomain()
Cookie
public void setDomain(String domain)
Cookie
public String getPath()
Cookie
public void setPath(String path)
Cookie
public String getComment()
Cookie
getComment
in interface Cookie
public void setComment(String comment)
Cookie
setComment
in interface Cookie
public String getCommentUrl()
Cookie
getCommentUrl
in interface Cookie
public void setCommentUrl(String commentUrl)
Cookie
setCommentUrl
in interface Cookie
public boolean isDiscard()
Cookie
public void setDiscard(boolean discard)
Cookie
setDiscard
in interface Cookie
public Set<Integer> getPorts()
Cookie
public void setPorts(int... ports)
Cookie
public void setPorts(Iterable<Integer> ports)
Cookie
public int getMaxAge()
Cookie
public void setMaxAge(int maxAge)
Cookie
0
is specified,
this cookie will be removed by browser because it will be expired
immediately. If Integer.MIN_VALUE
is specified, this cookie will be removed
when a user terminates browser.public int getVersion()
Cookie
getVersion
in interface Cookie
public void setVersion(int version)
Cookie
setVersion
in interface Cookie
public boolean isSecure()
Cookie
public void setSecure(boolean secure)
Cookie
public boolean isHttpOnly()
Cookie
isHttpOnly
in interface Cookie
public void setHttpOnly(boolean httpOnly)
Cookie
setHttpOnly
in interface Cookie
public int compareTo(Cookie c)
compareTo
in interface Comparable<Cookie>
Copyright © 2008-2014 The Netty Project. All Rights Reserved.