- All Implemented Interfaces:
- IntSet, Cloneable
- Direct Known Subclasses:
- TidSet
public class UnsortedArrayIntSet
extends ArrayIntSet
a simplistic IntSet implementation that uses an unsorted array to keep elements.
Obviously this is O(N) and therefore not a good choice if the list grows,
but if we know there are only a few elements then it isn't worth to
do any sorting or fancy lookup - the JIT would beat algorithm.
If the set is empty there is no memory allocated for the elements