(Collection<?> c)
| 4109 | } |
| 4110 | |
| 4111 | @Override |
| 4112 | public boolean removeAll(Collection<?> c) { |
| 4113 | try { |
| 4114 | return super.removeAll(checkNotNull(c)); |
| 4115 | } catch (UnsupportedOperationException e) { |
| 4116 | Set<K> toRemove = new HashSet<>(); |
| 4117 | for (Entry<K, V> entry : map().entrySet()) { |
| 4118 | if (c.contains(entry.getValue())) { |
| 4119 | toRemove.add(entry.getKey()); |
| 4120 | } |
| 4121 | } |
| 4122 | return map().keySet().removeAll(toRemove); |
| 4123 | } |
| 4124 | } |
| 4125 | |
| 4126 | @Override |
| 4127 | public boolean retainAll(Collection<?> c) { |