Set-Cookie response header sent by the
origin server to the HTTP agent in order to maintain a conversational state.
Please do not use methods marked as @Obsolete. They have been rendered obsolete by RFC 6265
| Modifier and Type | Method and Description |
|---|---|
| public void | setComment(String comment)
If a user agent (web browser) presents this cookie to a user, the cookie's purpose will be described using this comment. |
| public void | |
| public void | setExpiryDate(Date
the expiryDate)Date after which this cookie is no longer valid.Sets expiration date. |
| public void | |
| public void | |
| public void | |
| public void | setVersion(int
the version of the cookie. version)Sets the version of the cookie specification to which this cookie conforms. |
| setComment | back to summary |
|---|---|
| public void setComment(String comment) If a user agent (web browser) presents this cookie to a user, the cookie's purpose will be described using this comment.
| |
| setDomain | back to summary |
|---|---|
| public void setDomain(String domain) Sets the domain attribute.
| |
| setExpiryDate | back to summary |
|---|---|
| public void setExpiryDate(Date expiryDate) Sets expiration date. Note the object returned by this method is considered immutable. Changing it (e.g. using setTime()) could result in undefined behaviour. Do so at your peril.
| |
| setPath | back to summary |
|---|---|
| public void setPath(String path) Sets the path attribute.
| |
| setSecure | back to summary |
|---|---|
| public void setSecure(boolean secure) Sets the secure attribute of the cookie.
When
| |
| setValue | back to summary |
|---|---|
| public void setValue(String value) | |
| setVersion | back to summary |
|---|---|
| public void setVersion(int version) Sets the version of the cookie specification to which this cookie conforms.
| |