| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.commons.httpclient.cookie.CookieSpecBase
org.apache.commons.httpclient.cookie.RFC2109Spec
public class RFC2109Spec
RFC 2109 specific cookie management functions
| Field Summary | |
|---|---|
| static String | SET_COOKIE_KEYCookie Response Header name for cookies processed by this spec. | 
| Fields inherited from class org.apache.commons.httpclient.cookie.CookieSpecBase | 
|---|
| LOG | 
| Fields inherited from interface org.apache.commons.httpclient.cookie.CookieSpec | 
|---|
| PATH_DELIM, PATH_DELIM_CHAR | 
| Constructor Summary | |
|---|---|
| RFC2109Spec()Default constructor | |
| Method Summary | |
|---|---|
|  boolean | domainMatch(String host,
            String domain)Performs domain-match as defined by the RFC2109. | 
|  String | formatCookie(Cookie cookie)Return a string suitable for sending in a "Cookie" header as defined in RFC 2109 | 
|  String | formatCookies(Cookie[] cookies)Create a RFC 2109 compliant "Cookie" header value containing all Cookies in cookies suitable for sending in a "Cookie"
  header | 
|  void | parseAttribute(NameValuePair attribute,
               Cookie cookie)Parse RFC 2109 specific cookie attribute and update the corresponsing Cookieproperties. | 
|  void | validate(String host,
         int port,
         String path,
         boolean secure,
         Cookie cookie)Performs RFC 2109 compliant Cookievalidation | 
| Methods inherited from class org.apache.commons.httpclient.cookie.CookieSpecBase | 
|---|
| formatCookieHeader, formatCookieHeader, getValidDateFormats, match, match, parse, parse, pathMatch, setValidDateFormats | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final String SET_COOKIE_KEY
| Constructor Detail | 
|---|
public RFC2109Spec()
| Method Detail | 
|---|
public void parseAttribute(NameValuePair attribute,
                           Cookie cookie)
                    throws MalformedCookieException
Cookie properties.
parseAttribute in interface CookieSpecparseAttribute in class CookieSpecBaseattribute - NameValuePair cookie attribute from the
 Set- Cookiecookie - Cookie to be updated
MalformedCookieException - if an exception occurs during parsing
public void validate(String host,
                     int port,
                     String path,
                     boolean secure,
                     Cookie cookie)
              throws MalformedCookieException
Cookie validation
validate in interface CookieSpecvalidate in class CookieSpecBasehost - the host from which the Cookie was receivedport - the port from which the Cookie was receivedpath - the path from which the Cookie was receivedsecure - true when the Cookie was received using a
 secure connectioncookie - The cookie to validate
MalformedCookieException - if an exception occurs during
 validation
public boolean domainMatch(String host,
                           String domain)
domainMatch in interface CookieSpecdomainMatch in class CookieSpecBasehost - The target host.domain - The cookie domain attribute.
public String formatCookie(Cookie cookie)
formatCookie in interface CookieSpecformatCookie in class CookieSpecBasecookie - a Cookie to be formatted as string
public String formatCookies(Cookie[] cookies)
Cookies in cookies suitable for sending in a "Cookie"
  header
formatCookies in interface CookieSpecformatCookies in class CookieSpecBasecookies - an array of Cookies to be formatted
| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||