Package org.wildfly.common.function
Class ThreadLocalStack<E>
java.lang.Object
org.wildfly.common.function.ThreadLocalStack<E>
A thread local stack data structure. In order to avoid memory churn the underlying
ArrayDeque is never freed. If we remove the deque when it is empty then this results
in excessive deque allocations.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
ThreadLocalStack
public ThreadLocalStack()
-
-
Method Details
-
push
-
peek
-
pop
-
isEmpty
public boolean isEmpty()
-