Interface ImList<E>

    • Method Detail

      • append

        ImList<E> append​(E e)
        Adds one item to the end of the ImList.
        Specified by:
        append in interface BaseList<E>
        Parameters:
        e - the value to insert
        Returns:
        a new ImList with the additional item at the end.
      • concat

        default ImList<E> concat​(java.lang.Iterable<? extends E> es)
        Efficiently adds items to the end of this ImList.
        Specified by:
        concat in interface BaseList<E>
        Specified by:
        concat in interface Transformable<E>
        Specified by:
        concat in interface UnmodIterable<E>
        Parameters:
        es - the values to insert
        Returns:
        a new ImList with the additional items at the end.
      • mutable

        MutableList<E> mutable()
        Returns a mutable list (builder)
      • replace

        ImList<E> replace​(int idx,
                          E e)
        Replace the item at the given index. Note: i.replace(i.size(), o) used to be equivalent to i.concat(o), but it probably won't be for the RRB tree implementation, so this will change too.
        Specified by:
        replace in interface BaseList<E>
        Parameters:
        idx - the index where the value should be stored.
        e - the value to store
        Returns:
        a new ImList with the replaced item
      • reverse

        default ImList<E> reverse()
        Returns a reversed copy of this list.
        Specified by:
        reverse in interface BaseList<E>