org.jboss.netty.handler.codec.http

## Class CookieDecoder

- java.lang.Object
- - org.jboss.netty.handler.codec.http.CookieDecoder

-     public class CookieDecoder
      extends Object

  Decodes an HTTP header value into `Cookie`s. This decoder can decode the HTTP cookie version 0, 1, and 2.

       HttpRequest req = ...;
       String value = req.getHeader("Cookie");
       Set<Cookie> cookies = new CookieDecoder().decode(value);

  See Also:
    `CookieEncoder`

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `CookieDecoder()` Creates a new decoder.
    `CookieDecoder(boolean lenient)` Deprecated. Use `CookieDecoder()` instead.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `Set<Cookie>` | `decode(String header)` Decodes the specified HTTP header value into `Cookie`s.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### CookieDecoder

          public CookieDecoder()

      Creates a new decoder.

    - #### CookieDecoder

          @Deprecated
          public CookieDecoder(boolean lenient)

      Deprecated. Use `CookieDecoder()` instead.

  - ### Method Detail

    - #### decode

          public Set<Cookie> decode(String header)

      Decodes the specified HTTP header value into `Cookie`s.
      Returns:
        the decoded `Cookie`s

Copyright © 2008-2012 The Netty Project. All Rights Reserved.