public class FixedArrayList<E> extends ArrayList<E>
添加元素时超长则会删除头部元素
modCount| Constructor and Description |
|---|
FixedArrayList(int maxSize) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(E e) |
void |
add(int index,
E element) |
boolean |
addAll(Collection<? extends E> c) |
boolean |
addAll(int index,
Collection<? extends E> c) |
static <E> FixedArrayList<E> |
create(int maxSize) |
clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSizeequals, hashCodecontainsAll, toStringfinalize, getClass, notify, notifyAll, wait, wait, waitcontainsAll, equals, hashCodeparallelStream, streampublic static <E> FixedArrayList<E> create(int maxSize)
public boolean add(E e)
public void add(int index,
E element)
public boolean addAll(Collection<? extends E> c)
Copyright © 2025. All rights reserved.