WebView.StartSafeBrowsing(Context, IValueCallback) Method

Definition

Starts Safe Browsing initialization.

[Android.Runtime.Register("startSafeBrowsing", "(Landroid/content/Context;Landroid/webkit/ValueCallback;)V", "", ApiSince=27)]
public static void StartSafeBrowsing (Android.Content.Context context, Android.Webkit.IValueCallback? callback);
[<Android.Runtime.Register("startSafeBrowsing", "(Landroid/content/Context;Landroid/webkit/ValueCallback;)V", "", ApiSince=27)>]
static member StartSafeBrowsing : Android.Content.Context * Android.Webkit.IValueCallback -> unit

Parameters

context
Context

Application Context.

callback
IValueCallback

will be called on the UI thread with true if initialization is successful, false otherwise.

Attributes

Remarks

Starts Safe Browsing initialization.

URL loads are not guaranteed to be protected by Safe Browsing until after callback is invoked with true. Safe Browsing is not fully supported on all devices. For those devices callback will receive false.

This should not be called if Safe Browsing has been disabled by manifest tag or WebSettings#setSafeBrowsingEnabled. This prepares resources used for Safe Browsing.

This should be called with the Application Context (and will always use the Application context to do its work regardless).

Java documentation for android.webkit.WebView.startSafeBrowsing(android.content.Context, android.webkit.ValueCallback<java.lang.Boolean>).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to