| Constructor and Description |
|---|
HashMultiSet()
|
HashMultiSet(MultiSet
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
contains(T key)
Test whether
key is present in this MultiSet.
|
Iterator |
iterator()
|
Set |
keySet()
Get the set of keys in this MultiSet.
|
int |
occurences(T key)
Get the number of times the element
key is present in this MultiSet.
|
void |
put(T key)
Put
key to the MultiSet once.
|
void |
put(T key, int howOften)
|
void |
putAll(Collection
Put all keys contained in
key into the MultiSet once.
|
void |
remove(T key)
Remove key from the MultiSet once.
|
void |
removeAll(T key)
Remove all occurrences of
key.
|
void |
removeN(T key, int n)
Remove key from the MultiSet once.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic boolean contains(T key)
MultiSet
key is present in this MultiSet.
public int occurences(T key)
MultiSet
key is present in this MultiSet.
occurences in interface
MultiSet<T>
key - the element queried.
key in this MultiSet.
public void put(T key, int howOften)
public void putAll(Collection<T> keys)
MultiSet
key into the MultiSet once.
public void remove(T key)
MultiSet
public void removeAll(T key)
MultiSet
key.
public void removeN(T key, int n)
MultiSet
public Set<T> keySet()
MultiSet