T - the type of the objects in this multiset.public interface MultiSet<T> extends java.util.Collection<T>, HTMLToString
HTMLToString.HTMLCellRenderer| Modifier and Type | Method and Description |
|---|---|
java.lang.Integer |
add(T par,
java.lang.Integer weight)
Adds the given object to the multiset, as many times as indicated by the
given weight parameter.
|
java.util.Set<T> |
baseSet()
returns an unmodifiable set of unique objects in the multiset.
|
boolean |
isLessOrEqual(MultiSet<T> multiSet)
returns true if this multiset is less or equal to the given multiset,
i.e.
|
java.lang.Integer |
occurrences(java.lang.Object source)
returns the number of occurrences of the given object in this multiset.
|
java.util.List<T> |
toList()
Converts this multiset to a list, such that each element occurs as often
as returned by the iterator of the multiset (its number of occurrences).
|
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, parallelStream, remove, removeAll, removeIf, retainAll, size, spliterator, stream, toArray, toArraytoHTMLStringjava.lang.Integer add(T par, java.lang.Integer weight)
par - the object to addweight - the number of times to add itjava.util.List<T> toList()
boolean isLessOrEqual(MultiSet<T> multiSet)
multiSet - the multiset to testjava.lang.Integer occurrences(java.lang.Object source)
source - the object to get the occurrences forjava.util.Set<T> baseSet()