requestMatchesPredicate

fun requestMatchesPredicate(predicate: (P) -> Boolean)(source)

Adds a condition to verify that the request matches the specified predicate.

This method allows users to define a custom predicate that will be applied to the request, enabling more flexible and granular request matching.

Parameters

predicate

A function that takes a request of type P as an input and returns a Boolean indicating whether the condition is satisfied. If request is null - it returns false.