public final class RecyclableByteBufferList extends ArrayList<ByteBuffer> implements Recyclable
ByteBuffer list which is recyclable.
This implementation does not allow null elements to be added.modCount| Modifier and Type | Method and Description |
|---|---|
boolean |
add(ByteBuffer element) |
void |
add(int index,
ByteBuffer element) |
boolean |
addAll(Collection<? extends ByteBuffer> c) |
boolean |
addAll(int index,
Collection<? extends ByteBuffer> c) |
int |
getCapacity() |
static RecyclableByteBufferList |
newInstance()
Create a new empty
RecyclableByteBufferList instance |
static RecyclableByteBufferList |
newInstance(int minCapacity)
Create a new empty
RecyclableByteBufferList instance with the given capacity. |
boolean |
recycle()
Recycle this instance.
|
ByteBuffer |
remove(int index) |
boolean |
remove(Object o) |
ByteBuffer |
set(int index,
ByteBuffer element) |
static int |
threadLocalCapacity() |
static int |
threadLocalSize() |
clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, removeAll, removeIf, removeRange, replaceAll, retainAll, size, sort, spliterator, subList, toArray, toArray, trimToSizeequals, hashCodecontainsAll, toStringfinalize, getClass, notify, notifyAll, wait, wait, waitcontainsAll, equals, hashCodeparallelStream, streampublic static RecyclableByteBufferList newInstance()
RecyclableByteBufferList instancepublic static RecyclableByteBufferList newInstance(int minCapacity)
RecyclableByteBufferList instance with the given capacity.public int getCapacity()
public boolean addAll(Collection<? extends ByteBuffer> c)
addAll in interface Collection<ByteBuffer>addAll in interface List<ByteBuffer>addAll in class ArrayList<ByteBuffer>public boolean addAll(int index,
Collection<? extends ByteBuffer> c)
addAll in interface List<ByteBuffer>addAll in class ArrayList<ByteBuffer>public boolean add(ByteBuffer element)
add in interface Collection<ByteBuffer>add in interface List<ByteBuffer>add in class ArrayList<ByteBuffer>public void add(int index,
ByteBuffer element)
add in interface List<ByteBuffer>add in class ArrayList<ByteBuffer>public ByteBuffer set(int index, ByteBuffer element)
set in interface List<ByteBuffer>set in class ArrayList<ByteBuffer>public ByteBuffer remove(int index)
remove in interface List<ByteBuffer>remove in class ArrayList<ByteBuffer>public boolean remove(Object o)
remove in interface Collection<ByteBuffer>remove in interface List<ByteBuffer>remove in class ArrayList<ByteBuffer>public boolean recycle()
Recyclablerecycle in interface Recyclablepublic static int threadLocalCapacity()
public static int threadLocalSize()
Copyright © 2024. All rights reserved.