Interface BaseSeq<T>

    • Method Detail

      • get

        T get​(int index)
        Return the value at the given index.
        Parameters:
        index - index of the element to return.
        Returns:
        the value at the given index.
        Throws:
        IndexOutOfBoundsException - if the index is out of range (index < 0 || index >= size()).
      • length

        int length()
        Return the length of this sequence. Once the sequence is created, the length can't be changed.
        Returns:
        the length of this sequence.
      • isEmpty

        default boolean isEmpty()
        Returns true if this sequence contains no elements.
        Returns:
        true if this sequence contains no elements
        Since:
        6.0
      • nonEmpty

        default boolean nonEmpty()
        Returns true if this sequence contains at least one element.
        Returns:
        true if this sequence contains at least one element
        Since:
        6.0
      • listIterator

        default ListIterator<TlistIterator()
        Returns a list iterator over the elements in this sequence (in proper order).
        Returns:
        a list iterator over the elements in this sequence (in proper order)
      • stream

        default Stream<Tstream()
        Returns a sequential Stream with this sequence as its source.
        Returns:
        a sequential Stream over the elements in this sequence