retainAll

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

Retains only the elements in this set that are contained in the specified collection.

Return

true if this set changed as a result of the call

Parameters

elements

elements to be retained in this set

Throws

if the specified collection is null