|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectjava.beans.VetoableChangeSupport
ice.util.net.CookieManager
This class provides support for file cookies. It should NOT be used manually. If a cookieManager is needed, use ice.net.CookieManager instead.
| Constructor Summary | |
protected |
CookieManager()
|
| Method Summary | |
void |
addCookie(Cookie c)
Add one cookie to the list of cookies maintained by the CookieManager. |
void |
addCookie(String documentUrl,
String s)
|
void |
addVetoableChangeListener(VetoableChangeListener vc)
Register a listener for Cookie events. |
protected void |
applyAllCookies(URL url,
URLConnection uc)
Apply any cookies found for this URL. |
Enumeration |
elements()
Returns an Enumeration of Cookie objects. |
protected boolean |
extractAllCookies(URL url,
URLConnection uc)
Extracts any and all cookies found for this URL, and stores them. |
Cookie[] |
getAllCookies()
Returns an array of Cookie objects. |
String |
getCookieStr(String documentUrl)
|
static CookieManager |
getInstance()
|
int |
getMaxCookieSize()
Get the maximum allowed size for a single cookie. |
int |
getMaxNumberOfCookies()
Get the maximum allowed number of cookies. |
int |
getMaxTotalCookieSize()
Return the total maximum size allowed for cookies. |
boolean |
isEnabled()
Returns true if cookies are enabled. |
void |
readCookies(ObjectInput in)
Reads cookies from an object stream |
void |
removeAllCookies()
Removes all cookies. |
void |
removeAllExpiredCookies()
Remove all cookies which has expired. |
void |
removeAllSessionCookies()
Remove all session cookies, that is all cookies that are only valid for the current session. |
void |
setEnabled(boolean enable)
Enable/Disable cookies. |
void |
setMaxCookieSize(int newSize)
Set the maximum size of cookies in bytes. |
void |
setMaxNumberOfCookies(int maxCount)
Set the maximum allowed number of cookies. |
void |
setMaxTotalCookieSize(int newSize)
Set the maximum total size of all cookies in bytes. |
void |
writeCookies(ObjectOutput out)
Writes all stored cookies to an object stream |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
protected CookieManager()
| Method Detail |
public static CookieManager getInstance()
public int getMaxTotalCookieSize()
public void setMaxTotalCookieSize(int newSize)
public void setMaxCookieSize(int newSize)
public int getMaxCookieSize()
public void setMaxNumberOfCookies(int maxCount)
public int getMaxNumberOfCookies()
public void setEnabled(boolean enable)
public boolean isEnabled()
public Enumeration elements()
public Cookie[] getAllCookies()
elements()
protected boolean extractAllCookies(URL url,
URLConnection uc)
url - The actual url.uc - The URLconenction we extract cookies from.
applyAllCookies(java.net.URL, java.net.URLConnection)public void removeAllCookies()
public void removeAllSessionCookies()
public void removeAllExpiredCookies()
public void addCookie(Cookie c)
public void addCookie(String documentUrl,
String s)
addCookie in interface CookieSetpublic String getCookieStr(String documentUrl)
getCookieStr in interface CookieSet
protected void applyAllCookies(URL url,
URLConnection uc)
url - The (not connected)url that may have cookies.uc - The urlconnection to recieve the cookies.extractAllCookies(java.net.URL, java.net.URLConnection)public void writeCookies(ObjectOutput out)
out - The object stream to write to.public void readCookies(ObjectInput in)
in - The object stream to read frompublic void addVetoableChangeListener(VetoableChangeListener vc)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||