org.jboss.netty.handler.codec.http

## Interface Cookie

All Superinterfaces:
  Comparable<Cookie>

All Known Implementing Classes:
  DefaultCookie

    public interface Cookie
    extends Comparable<Cookie>

An HTTP Cookie.

### Method Summary

Methods
`String` `getComment()` Returns the comment of this cookie.
`String` `getCommentUrl()` Returns the comment URL of this cookie.
`String` `getDomain()` Returns the domain of this cookie.
`int` `getMaxAge()` Returns the max age of this cookie in seconds.
`String` `getName()` Returns the name of this cookie.
`String` `getPath()` Returns the path of this cookie.
`Set<Integer>` `getPorts()` Returns the ports of this cookie.
`String` `getValue()` Returns the value of this cookie.
`int` `getVersion()` Returns the version of this cookie.
`boolean` `isDiscard()` Returns the discard flag of this cookie.
`boolean` `isHttpOnly()` Returns if this cookie cannot be accessed through client side script.
`boolean` `isSecure()` Returns the secure flag of this cookie.
`void` `setComment(String comment)` Sets the comment of this cookie.
`void` `setCommentUrl(String commentUrl)` Sets the comment URL of this cookie.
`void` `setDiscard(boolean discard)` Sets the discard flag of this cookie.
`void` `setDomain(String domain)` Sets the domain of this cookie.
`void` `setHttpOnly(boolean httpOnly)` Sets if this cookie cannot be accessed through client side script.
`void` `setMaxAge(int maxAge)` Sets the max age of this cookie in seconds.
`void` `setPath(String path)` Sets the path of this cookie.
`void` `setPorts(int... ports)` Sets the ports of this cookie.
`void` `setPorts(Iterable<Integer> ports)` Sets the ports of this cookie.
`void` `setSecure(boolean secure)` Sets the secure flag of this cookie.
`void` `setValue(String value)` Sets the value of this cookie.
`void` `setVersion(int version)` Sets the version of this cookie.

### Methods inherited from interface java.lang.Comparable

`compareTo`

### Method Detail

#### getName

    String getName()

Returns the name of this cookie.

#### getValue

    String getValue()

Returns the value of this cookie.

#### setValue

    void setValue(String value)

Sets the value of this cookie.

#### getDomain

    String getDomain()

Returns the domain of this cookie.

#### setDomain

    void setDomain(String domain)

Sets the domain of this cookie.

#### getPath

    String getPath()

Returns the path of this cookie.

#### setPath

    void setPath(String path)

Sets the path of this cookie.

#### getComment

    String getComment()

Returns the comment of this cookie.

#### setComment

    void setComment(String comment)

Sets the comment of this cookie.

#### getMaxAge

    int getMaxAge()

Returns the max age of this cookie in seconds.

#### setMaxAge

    void setMaxAge(int maxAge)

Sets the max age of this cookie in seconds. If `0` is specified, this cookie will be removed by browser because it will be expired immediately. If `Integer.MIN_VALUE` is specified, this cookie will be removed when a user terminates browser.

#### getVersion

    int getVersion()

Returns the version of this cookie.

#### setVersion

    void setVersion(int version)

Sets the version of this cookie.

#### isSecure

    boolean isSecure()

Returns the secure flag of this cookie.

#### setSecure

    void setSecure(boolean secure)

Sets the secure flag of this cookie.

#### isHttpOnly

    boolean isHttpOnly()

Returns if this cookie cannot be accessed through client side script. This flag works only if the browser supports it. For more information, see here.

#### setHttpOnly

    void setHttpOnly(boolean httpOnly)

Sets if this cookie cannot be accessed through client side script. This flag works only if the browser supports it. For more information, see here.

#### getCommentUrl

    String getCommentUrl()

Returns the comment URL of this cookie.

#### setCommentUrl

    void setCommentUrl(String commentUrl)

Sets the comment URL of this cookie.

#### isDiscard

    boolean isDiscard()

Returns the discard flag of this cookie.

#### setDiscard

    void setDiscard(boolean discard)

Sets the discard flag of this cookie.

#### getPorts

    Set<Integer> getPorts()

Returns the ports of this cookie.

#### setPorts

    void setPorts(int... ports)

Sets the ports of this cookie.

#### setPorts

    void setPorts(Iterable<Integer> ports)

Sets the ports of this cookie.