Modifies multisetToModify so that its count for an element e is at most multisetToRetain.count(e). To be precise, multisetToModify.count(e) is set to Math.min(multisetToModify.count(e), multisetToRetain.count(e)). This is similar to {@link #intersection(Mu
(Multiset<?> multisetToModify, Multiset<?> multisetToRetain)
| 700 | */ |
| 701 | |
| 702 | @CanIgnoreReturnValue |
| 703 | public static boolean retainOccurrences(Multiset<?> multisetToModify, Multiset<?> multisetToRetain) { |
| 704 | return retainOccurrencesImpl(multisetToModify, multisetToRetain); |
| 705 | } |
| 706 | |
| 707 | /** |
| 708 | * Delegate implementation which cares about the element type. |
nothing calls this directly
no test coverage detected