Loading api/current.txt +2 −0 Original line number Diff line number Diff line Loading @@ -35267,6 +35267,7 @@ package android.webkit { public class CookieManager { method public synchronized boolean acceptCookie(); method public synchronized boolean acceptThirdPartyCookies(android.webkit.WebView); method public static boolean allowFileSchemeCookies(); method public java.lang.String getCookie(java.lang.String); method public static synchronized android.webkit.CookieManager getInstance(); Loading @@ -35278,6 +35279,7 @@ package android.webkit { method public void removeSessionCookies(android.webkit.ValueCallback<java.lang.Boolean>); method public synchronized void setAcceptCookie(boolean); method public static void setAcceptFileSchemeCookies(boolean); method public synchronized void setAcceptThirdPartyCookies(android.webkit.WebView, boolean); method public void setCookie(java.lang.String, java.lang.String); method public void setCookie(java.lang.String, java.lang.String, android.webkit.ValueCallback<java.lang.Boolean>); } core/java/android/webkit/CookieManager.java +30 −1 Original line number Diff line number Diff line Loading @@ -68,6 +68,35 @@ public class CookieManager { throw new MustOverrideException(); } /** * Sets whether the {@link WebView} should allow third party cookies to be set. * Allowing third party cookies is a per WebView policy and can be set * differently on different WebView instances. * <p> * Apps that target {@link android.os.Build.VERSION_CODES#KITKAT} or below * default to allowing third party cookies. Apps targeting * {@link android.os.Build.VERSION_CODES#L} or later default to disallowing * third party cookies. * * @param webview the {@link WebView} instance to set the cookie policy on * @param accept whether the {@link WebView} instance should accept * third party cookies */ public synchronized void setAcceptThirdPartyCookies(WebView webview, boolean accept) { throw new MustOverrideException(); } /** * Gets whether the {@link WebView} should allow third party cookies to be set. * * @param webview the {@link WebView} instance to get the cookie policy for * @return true if the {@link WebView} accepts third party cookies */ public synchronized boolean acceptThirdPartyCookies(WebView webview) { throw new MustOverrideException(); } /** * Sets a cookie for the given URL. Any existing cookie with the same host, * path and name will be replaced with the new cookie. The cookie being set Loading core/java/android/webkit/WebSettings.java +18 −0 Original line number Diff line number Diff line Loading @@ -499,6 +499,24 @@ public abstract class WebSettings { throw new MustOverrideException(); } /** * Sets policy for third party cookies. * Developers should access this via {@link CookieManager#setShouldAcceptThirdPartyCookies}. * @hide Internal API. */ public void setAcceptThirdPartyCookies(boolean accept) { throw new MustOverrideException(); } /** * Gets policy for third party cookies. * Developers should access this via {@link CookieManager#getShouldAcceptThirdPartyCookies}. * @hide Internal API */ public boolean getAcceptThirdPartyCookies() { throw new MustOverrideException(); } /** * Sets the text size of the page. The default is {@link TextSize#NORMAL}. * Loading Loading
api/current.txt +2 −0 Original line number Diff line number Diff line Loading @@ -35267,6 +35267,7 @@ package android.webkit { public class CookieManager { method public synchronized boolean acceptCookie(); method public synchronized boolean acceptThirdPartyCookies(android.webkit.WebView); method public static boolean allowFileSchemeCookies(); method public java.lang.String getCookie(java.lang.String); method public static synchronized android.webkit.CookieManager getInstance(); Loading @@ -35278,6 +35279,7 @@ package android.webkit { method public void removeSessionCookies(android.webkit.ValueCallback<java.lang.Boolean>); method public synchronized void setAcceptCookie(boolean); method public static void setAcceptFileSchemeCookies(boolean); method public synchronized void setAcceptThirdPartyCookies(android.webkit.WebView, boolean); method public void setCookie(java.lang.String, java.lang.String); method public void setCookie(java.lang.String, java.lang.String, android.webkit.ValueCallback<java.lang.Boolean>); }
core/java/android/webkit/CookieManager.java +30 −1 Original line number Diff line number Diff line Loading @@ -68,6 +68,35 @@ public class CookieManager { throw new MustOverrideException(); } /** * Sets whether the {@link WebView} should allow third party cookies to be set. * Allowing third party cookies is a per WebView policy and can be set * differently on different WebView instances. * <p> * Apps that target {@link android.os.Build.VERSION_CODES#KITKAT} or below * default to allowing third party cookies. Apps targeting * {@link android.os.Build.VERSION_CODES#L} or later default to disallowing * third party cookies. * * @param webview the {@link WebView} instance to set the cookie policy on * @param accept whether the {@link WebView} instance should accept * third party cookies */ public synchronized void setAcceptThirdPartyCookies(WebView webview, boolean accept) { throw new MustOverrideException(); } /** * Gets whether the {@link WebView} should allow third party cookies to be set. * * @param webview the {@link WebView} instance to get the cookie policy for * @return true if the {@link WebView} accepts third party cookies */ public synchronized boolean acceptThirdPartyCookies(WebView webview) { throw new MustOverrideException(); } /** * Sets a cookie for the given URL. Any existing cookie with the same host, * path and name will be replaced with the new cookie. The cookie being set Loading
core/java/android/webkit/WebSettings.java +18 −0 Original line number Diff line number Diff line Loading @@ -499,6 +499,24 @@ public abstract class WebSettings { throw new MustOverrideException(); } /** * Sets policy for third party cookies. * Developers should access this via {@link CookieManager#setShouldAcceptThirdPartyCookies}. * @hide Internal API. */ public void setAcceptThirdPartyCookies(boolean accept) { throw new MustOverrideException(); } /** * Gets policy for third party cookies. * Developers should access this via {@link CookieManager#getShouldAcceptThirdPartyCookies}. * @hide Internal API */ public boolean getAcceptThirdPartyCookies() { throw new MustOverrideException(); } /** * Sets the text size of the page. The default is {@link TextSize#NORMAL}. * Loading