Class UnmodifiableArraySet<E>

java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractSet<E>
com.aoapps.collections.UnmodifiableArraySet<E>
All Implemented Interfaces:
Externalizable, Serializable, Iterable<E>, Collection<E>, Set<E>

public class UnmodifiableArraySet<E> extends AbstractSet<E> implements Externalizable

An unmodifiable compact Set implementation that stores the elements in hashCode order. The emphasis is to use as little heap space as possible - this is not a general-purpose Set implementation.

This set does not support null values.

This set will generally operate at O(log n) due to binary search. In general, it will not be as fast as the O(1) behavior of HashSet. Here we give up speed to save space.

This set is not thread safe.

Author:
AO Industries, Inc.
See Also: