| public abstract class java.net CookieHandler
|
Java SE 6 |
A system-wide CookieHandler that to used by the HTTP protocol handler can be registered by doing a CookieHandler.setDefault(CookieHandler). The currently registered CookieHandler can be retrieved by calling CookieHandler.getDefault(). For more information on HTTP state management, see RFC 2965: HTTP State Management Mechanism
| version | 1.4, 03/08/09 |
| since | 1.5 |
| Constructors | |
|---|---|
| public | CookieHandler() |
| Methods | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| abstract public Map | get(URI uri, Map requestHeaders) throws IOException Gets all the applicable cookies from a cookie cache for the specified uri in the request header. HTTP protocol implementers should make sure that this method is called after all request headers related to choosing cookies are added, and before the request is sent.
| ||||||||||||
| abstract public void | put(URI uri, Map responseHeaders) throws IOException Sets all the applicable cookies, examples are response header fields that are named Set-Cookie2, present in the response headers into a cookie cache.
| ||||||||||||
| Properties | |||||||
|---|---|---|---|---|---|---|---|
| public static void | setDefault(CookieHandler cHandler) Sets (or unsets) the system-wide cookie handler. Note: non-standard http protocol handlers may ignore this setting.
| ||||||
| public static CookieHandler | getDefault() Gets the system-wide cookie handler.
| ||||||
| About DocWeb · Bundles · Export · Export All | Top 10 · Statistics · Login |
| About Sun · Contact · Privacy · Terms of Use · Trademarks | Java SE 6 · Copyright © 1994-2009 Sun Microsystems, Inc.All rights reserved. Use is subject to license terms |
![]() |
![]() |
|