List of utility methods to do Collection Remove
Collection | removeElementsOfList(Collection remove Elements Of List for (E element : elementsToRemove) { if (set.contains(element)) { set.remove(element); return set; |
void | removeIfNotPresent(Collection remove If Not Present for (Iterator<T> iter = collection.iterator(); iter.hasNext();) { T element = iter.next(); if (!permitted.contains(element)) { iter.remove(); |
void | removeOutStrings(Collection Remove um string da colecao caso seja igual ao parametro 'newString' for (Iterator<String> iterator = values.iterator(); iterator.hasNext();) { String tmp = (String) iterator.next(); if (tmp.equals(newString)) { iterator.remove(); |
Collection | removeRightSet(Collection left, Collection right) remove Right Set Collection set = new ArrayList(left); set.removeAll(right); return set; |
boolean | removeSafe(Collection Type-safe wrapper for Collection#remove(Object) method. return collection.remove(value);
|