Apache JMeter

## org.apache.jmeter.protocol.http.control
Interface CookieHandler

All Known Implementing Classes:
  HC3CookieHandler

    public interface CookieHandler

Interface to be implemented by CookieHandler

Method Summary
`void` `addCookieFromHeader(CookieManager cookieManager, boolean checkCookies, String cookieHeader, URL url)` Add cookie to CookieManager from cookieHeader and URL
`String` `getCookieHeaderForURL(CollectionProperty cookiesCP, URL url, boolean allowVariableCookie)` Find cookies applicable to the given URL and build the Cookie header from them.

Method Detail

### addCookieFromHeader

    void addCookieFromHeader(CookieManager cookieManager,
                             boolean checkCookies,
                             String cookieHeader,
                             URL url)

  Add cookie to CookieManager from cookieHeader and URL

  Parameters:
    `cookieManager` - CookieManager on which cookies are added
    `checkCookies` - boolean to indicate if cookies must be validated against spec
    `cookieHeader` - String cookie Header
    `url` - URL

### getCookieHeaderForURL

    String getCookieHeaderForURL(CollectionProperty cookiesCP,
                                 URL url,
                                 boolean allowVariableCookie)

  Find cookies applicable to the given URL and build the Cookie header from them.

  Parameters:
    `cookiesCP` - `CollectionProperty` of `Cookie`
    `url` - URL of the request to which the returned header will be added.
  Returns:
    the value string for the cookie header (goes after "Cookie: ").

Apache JMeter

Copyright © 1998-2012 Apache Software Foundation. All Rights Reserved.