code: @Override
    public I getItem(int relativeOffset, Function<? super Integer, I> endFunction) {
      int index = wordIndex + relativeOffset;
  
      if (index < 0) {
        return endFunction.apply(index);
      } else if (index >= items.size()) {
        int endWordIndex = index - (items.size() - 1);
        return endFunction.apply(endWordIndex);
      } else {
        return items.get(index);
      }
    }
docs: Gets an item to the left or right of the central item in this
  context. Negative offsets get an item on the left (e.g., -2 gets
  the second item on the left) and positive offsets get an item on
  the right. If {@code relativeOffset} refers to a word off the end
  of the sequence, then {@code endFunction} is invoked to produce the
  return value.
  
  @param relativeOffset
  @return