brutil
Interface MultiSet
- All Superinterfaces:
- Collection, Set
- All Known Subinterfaces:
- SortedMultiSet
- All Known Implementing Classes:
- AbstractMultiSet, AbstractSortedList
- public interface MultiSet
- extends Set
Same as the Set interface, only a MultiSet may contain more than
one instance of a single object.
|
Method Summary |
int |
numOccurences(java.lang.Object o)
Return the number of times the specified object occurs in the
set. |
boolean |
removeAll(java.lang.Object o)
Remove all instances of specified object from the MultiSet |
removeAll
public boolean removeAll(java.lang.Object o)
- Remove all instances of specified object from the MultiSet
- Parameters:
o - The object to remove.- Returns:
true if the object was in the set,
false otherwise.
numOccurences
public int numOccurences(java.lang.Object o)
- Return the number of times the specified object occurs in the
set.
- Parameters:
o - The object to find the number of instance to- Returns:
- number of instances of the specified object.