arrow-optics / arrow.optics.extensions / MapFilterIndex


interface MapFilterIndex<K, V> : FilterIndex<Map<K, V>, K, V>

FilterIndex instance definition for Map.


filter open fun filter(p: Predicate<K>): Traversal<Map<K, V>, V>
Filter the foci A of a Traversal with the predicate p.

Companion Object Functions

invoke operator fun <K, V> invoke(): MapFilterIndex<K, V>
Operator overload to instantiate typeclass instance.