Top Description Constructors Methods
org.apache.http.impl.cookie

public Class RFC2965VersionAttributeHandler

extends Object
implements CommonCookieAttributeHandler
Class Inheritance
All Implemented Interfaces
org.apache.http.cookie.CommonCookieAttributeHandler, org.apache.http.cookie.CookieAttributeHandler
Annotations
@Contract
threading:IMMUTABLE
Imports
org.apache.http.annotation.Contract, .ThreadingBehavior, org.apache.http.cookie.ClientCookie, .CommonCookieAttributeHandler, .Cookie, .CookieOrigin, .CookieRestrictionViolationException, .MalformedCookieException, .SetCookie, .SetCookie2, org.apache.http.util.Args

"Version" cookie attribute handler for RFC 2965 cookie spec.
Since
4.0

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public String
public boolean
match(final Cookie cookie, final CookieOrigin
the cookie source to match against
origin
)

Implements org.apache.http.cookie.CookieAttributeHandler.match.

Matches the given value (property of the destination host where request is being submitted) with the corresponding cookie attribute.
public void
parse(final SetCookie cookie, final String
cookie attribute value from the cookie response header
value
)

Implements org.apache.http.cookie.CookieAttributeHandler.parse.

Parse cookie version attribute.
public void
validate(final Cookie cookie, final CookieOrigin
the cookie source to validate against
origin
)

Implements org.apache.http.cookie.CookieAttributeHandler.validate.

validate cookie version attribute.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RFC2965VersionAttributeHandlerback to summary
public RFC2965VersionAttributeHandler()

Method Detail

getAttributeNameback to summary
public String getAttributeName()

Implements org.apache.http.cookie.CommonCookieAttributeHandler.getAttributeName.

Annotations
@Override
matchback to summary
public boolean match(final Cookie cookie, final CookieOrigin origin)

Implements org.apache.http.cookie.CookieAttributeHandler.match.

Doc from org.apache.http.cookie.CookieAttributeHandler.match.

Matches the given value (property of the destination host where request is being submitted) with the corresponding cookie attribute.

Parameters
cookie:Cookie

org.apache.http.cookie.Cookie to match

origin:CookieOrigin

the cookie source to match against

Returns:boolean

true if the match is successful; false otherwise

Annotations
@Override
parseback to summary
public void parse(final SetCookie cookie, final String value) throws MalformedCookieException

Implements org.apache.http.cookie.CookieAttributeHandler.parse.

Parse cookie version attribute.

Parameters
cookie:SetCookie

Doc from org.apache.http.cookie.CookieAttributeHandler.parse.

org.apache.http.cookie.Cookie to be updated

value:String

Doc from org.apache.http.cookie.CookieAttributeHandler.parse.

cookie attribute value from the cookie response header

Annotations
@Override
validateback to summary
public void validate(final Cookie cookie, final CookieOrigin origin) throws MalformedCookieException

Implements org.apache.http.cookie.CookieAttributeHandler.validate.

validate cookie version attribute. Version attribute is REQUIRED.

Parameters
cookie:Cookie

Doc from org.apache.http.cookie.CookieAttributeHandler.validate.

org.apache.http.cookie.Cookie to validate

origin:CookieOrigin

Doc from org.apache.http.cookie.CookieAttributeHandler.validate.

the cookie source to validate against

Annotations
@Override
Exceptions
MalformedCookieException:

Doc from org.apache.http.cookie.CookieAttributeHandler.validate.

if cookie validation fails for this attribute