|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | POINTCUT | FIELD | CONSTRUCTOR | METHOD | DETAIL: FIELD | POINTCUT | CONSTRUCTOR | METHOD |
java.lang.Object | +--org.apache.cactus.Cookie
Client cookie. Used for manipulating client cookies either in
beginXXX()
(to send cookies) or in
endXXX()
methods (to assert returned cookies).
Constructor Summary | |
Cookie(String theDomain,
String theName,
String theValue)
Create a cookie. |
Method Summary | |
boolean |
equals(Object theObject)
Two cookies match if the name, path and domain match. Affected by: LogAspect |
String |
getComment()
Returns the comment describing the purpose of this cookie, or null if no such comment has been defined. |
String |
getDomain()
Returns the domain of this cookie. |
Date |
getExpiryDate()
Return the expiry date. |
String |
getName()
|
String |
getPath()
Return the path this cookie is associated with. |
String |
getValue()
|
int |
hashCode()
Hash up name, value and domain into new hash. |
boolean |
isExpired()
|
boolean |
isSecure()
|
boolean |
isToBeDiscarded()
|
void |
setComment(String theComment)
If a user agent (web browser) presents this cookie to a user, the cookie's purpose will be described using this comment. Affected by: LogAspect |
void |
setDomain(String theDomain)
Sets the cookie domain. Affected by: LogAspect |
void |
setExpiryDate(Date theExpiryDate)
Set the cookie expires date. Affected by: LogAspect |
void |
setName(String theName)
Sets the cookie name Affected by: LogAspect |
void |
setPath(String thePath)
Sets the cookie path. Affected by: LogAspect |
void |
setSecure(boolean isSecure)
Indicates to the user agent that the cookie should only be sent using a secure protocol (https). Affected by: LogAspect |
void |
setValue(String theValue)
Sets the cookie value Affected by: LogAspect |
String |
toString()
|
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Cookie(String theDomain, String theName, String theValue)
theDomain
- the cookie domain
theName
- the cookie name
theValue
- the cookie value
Method Detail |
public boolean equals(Object theObject)
theObject
- the cookie object to match
around() in LogAspect
.public String getComment()
public String getDomain()
public Date getExpiryDate()
public String getName()
public String getPath()
public String getValue()
public int hashCode()
public boolean isExpired()
public boolean isSecure()
public boolean isToBeDiscarded()
public void setComment(String theComment)
theComment
- the cookie's text comment
around() in LogAspect
.public void setDomain(String theDomain)
theDomain
- the cookie domain
around() in LogAspect
.public void setExpiryDate(Date theExpiryDate)
Netscape's original proposal defined an Expires header that took a date value in a fixed-length variant format in place of Max-Age: Wdy, DD-Mon-YY HH:MM:SS GMT Note that the Expires date format contains embedded spaces, and that "old" cookies did not have quotes around values. Clients that implement to this specification should be aware of "old" cookies and Expires.
theExpiryDate
- the expires date.
around() in LogAspect
.public void setName(String theName)
theName
- the cookie name
around() in LogAspect
.public void setPath(String thePath)
thePath
- the cookie path
around() in LogAspect
.public void setSecure(boolean isSecure)
isSecure
- true if the cookie should be sent over secure
connections only
around() in LogAspect
.public void setValue(String theValue)
theValue
- the cookie value
around() in LogAspect
.public String toString()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTRUCTOR | METHOD | DETAIL: FIELD | CONSTRUCTOR | METHOD |