DuplicatesList<T> extension
- on
-
- List<
T>
- List<
Properties
- containsDuplicates → bool
-
Available on List<
Returns true if the iterable contains any duplicate elements. Example usage:T> , provided by the DuplicatesList extensionno setter -
duplicates
→ List<
T> -
Available on List<
Returns a new list containing only the duplicate elements from this list. Note that if an element is duplicated multiple times, it will appear multiple times in the result.T> , provided by the DuplicatesList extensionno setter - numberOfDuplicates → int
-
Available on List<
Returns the number of duplicate elements in the iterable. Note that this does not count the unique elements that are duplicated, but the total number of duplicates.T> , provided by the DuplicatesList extensionno setter -
uniques
→ List<
T> -
Available on List<
Returns a new list containing only the unique elements from this list. Example usage:T> , provided by the DuplicatesList extensionno setter
Methods
-
addAllByAvoidingDuplicates(
Iterable< T> values) → void -
Available on List<
Adds all elements fromT> , provided by the DuplicatesList extensionvaluesto this list, avoiding duplicates. -
removeDuplicates(
) → void -
Available on List<
Removes duplicate elements from the list in place.T> , provided by the DuplicatesList extension