android-components / mozilla.components.browser.engine.system.matcher / UrlMatcher / createMatcher

createMatcher

fun createMatcher(context: Context, blackListFile: Int, overrides: IntArray?, whiteListFile: Int, enabledCategories: Set<String> = SUPPORTED_CATEGORIES): UrlMatcher (source)

Creates a new matcher instance for the provided URL lists.

Parameters

blackListFile - resource ID to a JSON file containing the black list

overrides - array of resource ID to JSON files containing black list overrides

whiteListFile - resource ID to a JSON file containing the white list

fun createMatcher(black: Reader, overrides: List<Reader>?, white: Reader, enabledCategories: Set<String> = SUPPORTED_CATEGORIES): UrlMatcher (source)

Creates a new matcher instance for the provided URL lists.

Parameters

black - reader containing the black list

overrides - array of resource ID to JSON files containing black list overrides

white - resource ID to a JSON file containing the white list