Android Utililty Methods Collection Duplicate Remove

List of utility methods to do Collection Duplicate Remove

Description

The list of methods to do Collection Duplicate Remove are organized into topic(s).

Method

booleanhasUniqueObject(Collection collection)
Determine whether the given Collection only contains a single unique object.
if (isEmpty(collection)) {
    return false;
boolean hasCandidate = false;
Object candidate = null;
for (Object elem : collection) {
    if (!hasCandidate) {
        hasCandidate = true;
...
booleanhasUniqueObject(Collection collection)
Determine whether the given Collection only contains a single unique object.
if (isEmpty(collection)) {
    return false;
boolean hasCandidate = false;
Object candidate = null;
for (Object elem : collection) {
    if (!hasCandidate) {
        hasCandidate = true;
...