List of utility methods to do ConcurrentMap
int | remove(K key, ConcurrentMap remove outer: for (;;) { Object[] elements = map.get(key); if (elements != null) { int i, len = i = elements.length; while (--i >= 0) { if (value.equals(elements[i])) { if (--len > 0) { Object[] newElements = new Object[len]; ... |
boolean | removeFromContainedSet(ConcurrentMap remove From Contained Set Set<V> existingSet = map.get(mapKey); if (existingSet == null) { Set<V> newSet = Collections.newSetFromMap(new ConcurrentHashMap<>()); existingSet = map.putIfAbsent(mapKey, newSet); if (existingSet == null) { existingSet = newSet; return existingSet.remove(value); |