BRUtil - Making Java a Kinder, Gentler, Place to be.

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
 
Methods inherited from interface brutil.Set
add, contains, find, isEmpty, iterator, remove
 
Methods inherited from interface brutil.Collection
clear, size
 

Method Detail

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.


BRUtil - Making Java a Kinder, Gentler, Place to be.