Join us on the livestream at Android Dev Summit on 7-8 November 2018, starting at 10AM PDT!

SafeBrowsingResponseCompat

public abstract class SafeBrowsingResponseCompat
extends Object

java.lang.Object
   ↳ androidx.webkit.SafeBrowsingResponseCompat


Compatibility version of SafeBrowsingResponse.

Summary

Public methods

abstract void backToSafety(boolean report)

Act as if the user clicked "back to safety."

This method should only be called if WebViewFeature.isFeatureSupported(String) returns true for WebViewFeature.SAFE_BROWSING_RESPONSE_BACK_TO_SAFETY.

abstract void proceed(boolean report)

Act as if the user clicked "visit this unsafe site."

This method should only be called if WebViewFeature.isFeatureSupported(String) returns true for WebViewFeature.SAFE_BROWSING_RESPONSE_PROCEED.

abstract void showInterstitial(boolean allowReporting)

Display the default interstitial.

Inherited methods

Public methods

backToSafety

public abstract void backToSafety (boolean report)

Act as if the user clicked "back to safety."

This method should only be called if WebViewFeature.isFeatureSupported(String) returns true for WebViewFeature.SAFE_BROWSING_RESPONSE_BACK_TO_SAFETY.

Parameters
report boolean: true to enable Safe Browsing reporting.

proceed

public abstract void proceed (boolean report)

Act as if the user clicked "visit this unsafe site."

This method should only be called if WebViewFeature.isFeatureSupported(String) returns true for WebViewFeature.SAFE_BROWSING_RESPONSE_PROCEED.

Parameters
report boolean: true to enable Safe Browsing reporting.

showInterstitial

public abstract void showInterstitial (boolean allowReporting)

Display the default interstitial.

This method should only be called if WebViewFeature.isFeatureSupported(String) returns true for WebViewFeature.SAFE_BROWSING_RESPONSE_SHOW_INTERSTITIAL.

Parameters
allowReporting boolean: true if the interstitial should show a reporting checkbox.