retainAll

open override fun retainAll(elements: Collection<E>): Boolean

Retains only elements that are contained in the given collection.

All bulk operations preserve the weight array alignment with items and are performed in a single pass to avoid repeated shifting.

Return

true if the list changed as a result.