org.apache.commons.httpclient.cookie
Class RFC2109Spec
- CookieSpec
RFC 2109 specific cookie management functions
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
Cookie s 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
Cookie properties.
|
void | validate(String host, int port, String path, boolean secure, Cookie cookie) - Performs RFC 2109 compliant
Cookie validation
|
domainMatch , formatCookie , formatCookieHeader , formatCookieHeader , formatCookies , getValidDateFormats , match , match , parse , parse , parseAttribute , pathMatch , setValidDateFormats , validate |
RFC2109Spec
public RFC2109Spec()
Default constructor
domainMatch
public boolean domainMatch(String host,
String domain)
Performs domain-match as defined by the RFC2109.
- domainMatch in interface CookieSpec
- domainMatch in interface CookieSpecBase
host
- The target host.domain
- The cookie domain attribute.
- true if the specified host matches the given domain.
formatCookie
public String formatCookie(Cookie cookie)
Return a string suitable for sending in a "Cookie" header as
defined in RFC 2109
- formatCookie in interface CookieSpec
- formatCookie in interface CookieSpecBase
cookie
- a Cookie
to be formatted as string
- a string suitable for sending in a "Cookie" header.
formatCookies
public String formatCookies(Cookie[] cookies)
Create a RFC 2109 compliant
"Cookie" header value containing all
Cookie
s in
cookies suitable for sending in a
"Cookie"
header
- formatCookies in interface CookieSpec
- formatCookies in interface CookieSpecBase
cookies
- an array of Cookie
s to be formatted
- a string suitable for sending in a Cookie header.
Copyright (c) 1999-2005 - Apache Software Foundation