Here's a few use cases examples...
Cookiemanager cm = new CookieManager();
URL url = new URL("http://www.hccp.org/test/cookieTest.jsp");
. . .
// getting cookies:
URLConnection conn = url.openConnection();
conn.connect();
// setting cookies
cm.storeCookies(conn);
cm.setCookies(url.openConnection());
|
|