Interface IMultiset<T>

All Superinterfaces:
Clearable, IMemory<T>, IMemoryView<T>, Iterable<T>
All Known Implementing Classes:
EclipseCollectionsLongMultiset, EclipseCollectionsMultiset

public interface IMultiset<T> extends IMemory<T>
An IMemory that always contains values with a nonnegative multiplicity.

In case a write operation caused underflow, an IllegalStateException is thrown.

Since:
1.7
  • Method Details

    • addPositive

      boolean addPositive(T value, int count)
      Adds the given number of occurrences to the memory. The count value must be a positive number.
      Parameters:
      count - the number of occurrences
      Returns:
      true if the tuple was not present before in the memory