Class CopyList<E>

  • Type Parameters:
    E - the type of elements in this list
    All Implemented Interfaces:
    Iterable<E>, Collection<E>, List<E>, RandomAccess

    public final class CopyList<E>
    extends AbstractList<E>
    implements RandomAccess
    A List implementation initially based on given array, but never modifying the array directly. On the first modification, the implementation will create its own copy of the array, and after that it behaves mostly as an ArrayList.