updateRulesets

abstract suspend fun updateRulesets(vararg rulesetTypes: Ruleset.Type = allRulesets())

Request the Rulesets are updated from the service. This method must be called to update the local copy of the Rulesets before any Rulesets are made active by a call to setActiveRulesets.

Parameters

rulesetTypes

The Ruleset.Types to update. All Rulesets will be updated if this argument is not supplied.

Samples

launch {
    withContext(Dispatchers.IO) {
        // For example, if only interested in ads and privacy blocking
        client.updateRulesets(
            Ruleset.Type.AD_BLOCKING,
            Ruleset.Type.PRIVACY,
        )
    }
}