de.caff.generics

## Class MutableIndexable.ListView<T>

- java.lang.Object
- - java.util.AbstractCollection<E>
  - - java.util.AbstractList<T>
    - - de.caff.generics.MutableIndexable.ListView<T>

- All Implemented Interfaces:
    java.lang.Iterable<T>, java.util.Collection<T>, java.util.List<T>, java.util.RandomAccess
  Enclosing interface:
    MutableIndexable<T>

      public static class MutableIndexable.ListView<T>
      extends java.util.AbstractList<T>
      implements java.util.RandomAccess

  Helper class for viewing a mutable indexable as a standard list. The main purpose of this class is providing the RandomAccess modifier.

- - ### Field Summary

    - ### Fields inherited from class java.util.AbstractList

      `modCount`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ListView(MutableIndexable<T> indexable)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `T` | `get(int index)`
    `boolean` | `isEmpty()`
    `java.util.Iterator<T>` | `iterator()`
    `T` | `set(int index, T element)`
    `int` | `size()`

    - ### Methods inherited from class java.util.AbstractList

      `add, add, addAll, clear, equals, hashCode, indexOf, lastIndexOf, listIterator, listIterator, remove, removeRange, subList`

    - ### Methods inherited from class java.util.AbstractCollection

      `addAll, contains, containsAll, remove, removeAll, retainAll, toArray, toArray, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface java.util.List

      `addAll, contains, containsAll, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray`

    - ### Methods inherited from interface java.util.Collection

      `parallelStream, removeIf, stream`

    - ### Methods inherited from interface java.lang.Iterable

      `forEach`

- - ### Constructor Detail

    - #### ListView

          public ListView(@NotNull
                          MutableIndexable<T> indexable)

  - ### Method Detail

    - #### get

          public T get(int index)

      Specified by:
        `get` in interface `java.util.List<T>`
      Specified by:
        `get` in class `java.util.AbstractList<T>`

    - #### size

          public int size()

      Specified by:
        `size` in interface `java.util.Collection<T>`
      Specified by:
        `size` in interface `java.util.List<T>`
      Specified by:
        `size` in class `java.util.AbstractCollection<T>`

    - #### set

          public T set(int index,
                       T element)

      Specified by:
        `set` in interface `java.util.List<T>`
      Overrides:
        `set` in class `java.util.AbstractList<T>`

    - #### isEmpty

          public boolean isEmpty()

      Specified by:
        `isEmpty` in interface `java.util.Collection<T>`
      Specified by:
        `isEmpty` in interface `java.util.List<T>`
      Overrides:
        `isEmpty` in class `java.util.AbstractCollection<T>`

    - #### iterator

          public java.util.Iterator<T> iterator()

      Specified by:
        `iterator` in interface `java.lang.Iterable<T>`
      Specified by:
        `iterator` in interface `java.util.Collection<T>`
      Specified by:
        `iterator` in interface `java.util.List<T>`
      Overrides:
        `iterator` in class `java.util.AbstractList<T>`