UrlAllowList

open class UrlAllowList

Defines a set of URL patterns to match a URL.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
Interface that defines a callback that can be used to reject or allow a URL.
Link copied to clipboard
annotation class Scope

Properties

Link copied to clipboard
val SCOPE_ALL: Int = 3
UrlAllowList entry applies to both url and JS interface.
Link copied to clipboard
Allow list scope for testing web view URLs before injected the Airship JS interface (native bridge).
Link copied to clipboard
Allow list scope for testing URLs before loading them in either a web view or deep linking to them externally from the app.

Functions

Link copied to clipboard
open fun addEntry(@NonNull pattern: String): Boolean
open fun addEntry(@NonNull pattern: String, scope: Int): Boolean
Adds an entry to the URL allow list for URL matching.
Link copied to clipboard
open fun isAllowed(@Nullable url: String): Boolean
Checks if a given URL is allowed or not with scope SCOPE_ALL.
open fun isAllowed(@Nullable url: String, scope: Int): Boolean
Checks if a given URL is allowed or not.
Link copied to clipboard
Sets the urlAllowList callback.