From: http://developer.android.com/reference/android/webkit/CookieManager.html

public class

CookieManager
extends Objectjava.lang.Object
↳ android.webkit.CookieManager

Class Overview

Manages the cookies used by an application's WebView instances. Cookies are manipulated according to RFC2109.


SummaryPublic Methods :

synchronized boolean acceptCookie()

Gets whether the application's WebView instances send and accept cookies.
boolean acceptThirdPartyCookies(WebView webview)
Gets whether the WebView should allow third party cookies to be set.
static boolean allowFileSchemeCookies()
Gets whether the application's WebView instances send and accept cookies for file scheme URLs.
void flush()
Ensures all cookies currently accessible through the getCookie API are written to persistent storage.
String getCookie(String url)
Gets the cookies for the given URL.
synchronized static CookieManager getInstance()
Gets the singleton CookieManager instance.
synchronized boolean hasCookies()
Gets whether there are stored cookies.
void removeAllCookie()
This method was deprecated in API level 21. Use removeAllCookies(ValueCallback) instead.
void removeAllCookies(ValueCallback<Boolean> callback)
Removes all cookies.
void removeExpiredCookie()
This method was deprecated in API level 21. The WebView handles removing expired cookies automatically.
void removeSessionCookie()
This method was deprecated in API level 21. use removeSessionCookies(ValueCallback) instead.
void removeSessionCookies(ValueCallback<Boolean> callback)
Removes all session cookies, which are cookies without an expiration date.
synchronized void setAcceptCookie(boolean accept)
Sets whether the application's WebView instances should send and accept cookies.
static void setAcceptFileSchemeCookies(boolean accept)
Sets whether the application's WebView instances should send and accept cookies for file scheme URLs.
void setAcceptThirdPartyCookies(WebView webview, boolean accept)
Sets whether the WebView should allow third party cookies to be set.
void setCookie(String url, String value, ValueCallback<Boolean> callback)
Sets a cookie for the given URL.
void setCookie(String url, String value)
Sets a cookie for the given URL.
Protected Methods
Object clone()
Creates and returns a copy of this Object.
[Expand]
Inherited Methods
From class java.lang.Object

更多相关文章

  1. 代码中设置drawableleft
  2. android 3.0 隐藏 系统标题栏
  3. Android开发中activity切换动画的实现
  4. Android(安卓)学习 笔记_05. 文件下载
  5. Android中直播视频技术探究之—摄像头Camera视频源数据采集解析
  6. 技术博客汇总
  7. android 2.3 wifi (一)
  8. AndRoid Notification的清空和修改
  9. Android中的Chronometer

随机推荐

  1. 使用jQuery和AJAX从JSON文件加载数据
  2. XHTML 相对路径与绝对路径
  3. 15个基于WEB的HTML编辑器
  4. 另一个div内的任意宽度的中心div
  5. css3+html5——拼接图片中icon的使用、照
  6. 认识DHTML中的“行为”组件
  7. 如何从input type = file中删除一个对象?
  8. 如何在jquery中增加itemtype的值?
  9. xml格式原样输出到html或是jsp页面
  10. 用HTML+CSS编写一个计科院网站首页的静态