public class ConcurrentPooledLinkedList<T> extends org.mini2Dx.gdx.utils.PooledLinkedList<T> implements ConcurrentCollection
Modifier and Type | Field and Description |
---|---|
protected ReadWriteLock |
lock |
Constructor and Description |
---|
ConcurrentPooledLinkedList(int maxPoolSize) |
Modifier and Type | Method and Description |
---|---|
void |
add(T object)
Adds the specified object to the end of the list regardless of iteration status
|
void |
addFirst(T object)
Adds the specified object to the head of the list regardless of iteration status
|
void |
clear() |
ReadWriteLock |
getLock()
Returns the collection's
ReadWriteLock |
void |
iter()
Starts iterating over the list's items from the head of the list
|
void |
iterReverse()
Starts iterating over the list's items from the tail of the list
|
T |
next()
Gets the next item in the list
|
T |
previous()
Gets the previous item in the list
|
void |
remove()
Removes the current list item based on the iterator position.
|
T |
removeLast()
Removes the tail of the list regardless of iteration status
|
int |
size()
Returns the number of items in the list
|
protected ReadWriteLock lock
public void add(T object)
add
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
object
- public void addFirst(T object)
addFirst
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
object
- public int size()
size
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public void iter()
iter
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public void iterReverse()
iterReverse
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public T next()
next
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public T previous()
previous
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public void remove()
remove
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public T removeLast()
removeLast
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public void clear()
clear
in class org.mini2Dx.gdx.utils.PooledLinkedList<T>
public ReadWriteLock getLock()
ConcurrentCollection
ReadWriteLock
getLock
in interface ConcurrentCollection
ReadWriteLock