@Test public void testGetIndexHigh() { PreAllocatedArray<String> strings = new PreAllocatedArray<>(3); strings.get(2); assertThrows(IndexOutOfBoundsException.class, () -> strings.get(3)); }
public T get(final int index) { return internal.get(index); }
PreAllocatedArray implements Iterable<T> { public T get(final int index) { return internal.get(index); } }
PreAllocatedArray implements Iterable<T> { public T get(final int index) { return internal.get(index); } PreAllocatedArray(final int capacity); }
PreAllocatedArray implements Iterable<T> { public T get(final int index) { return internal.get(index); } PreAllocatedArray(final int capacity); T set(final int index, final T element); T get(final int index); @Override Iterator<T> iterator(); }
PreAllocatedArray implements Iterable<T> { public T get(final int index) { return internal.get(index); } PreAllocatedArray(final int capacity); T set(final int index, final T element); T get(final int index); @Override Iterator<T> iterator(); final int length; }