public class HttpCookie extends Object implements Cookie
Cookie implementation.| Modifier and Type | Class and Description |
|---|---|
static class |
HttpCookie.CookieBuilder
Default
Cookie builder. |
Cookie.BuilderDEFAULT_VERSION| Constructor and Description |
|---|
HttpCookie(String name,
String value)
Constructor with
Cookie.DEFAULT_VERSION and no path/domain |
HttpCookie(String name,
String value,
int version,
String path,
String domain)
Constructor
|
HttpCookie(String name,
String value,
String path,
String domain)
Constructor with
Cookie.DEFAULT_VERSION |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
String |
getDomain()
Get the domain of the cookie
|
String |
getName()
Get the name of the cookie
|
String |
getPath()
Get the path of the cookie
|
String |
getValue()
Get the value of the cookie
|
int |
getVersion()
Get the version of the cookie
|
int |
hashCode() |
void |
setDomain(String domain)
Set the cookie domain
|
void |
setName(String name)
Set the cookie name
|
void |
setPath(String path)
Set the cookie path
|
void |
setValue(String value)
Set the cookie value
|
void |
setVersion(int version)
Set the cookie version
|
String |
toString() |
public HttpCookie(String name, String value)
Cookie.DEFAULT_VERSION and no path/domainname - Namevalue - Valuepublic HttpCookie(String name, String value, String path, String domain)
Cookie.DEFAULT_VERSIONname - Namevalue - Valuepath - Pathdomain - Domainpublic String getName()
Cookiepublic String getValue()
Cookiepublic int getVersion()
CookiegetVersion in interface Cookiepublic String getDomain()
Cookiepublic String getPath()
Cookiepublic void setName(String name)
name - the name to set (not null)public void setValue(String value)
value - the value to setpublic void setVersion(int version)
version - the version to setpublic void setPath(String path)
path - the path to setpublic void setDomain(String domain)
domain - the domain to setCopyright © 2019 The Holon Platform. All rights reserved.