Package org.apache.johnzon.core
Class ThreadLocalBufferCache<T>
- java.lang.Object
-
- org.apache.johnzon.core.ThreadLocalBufferCache<T>
-
- All Implemented Interfaces:
Serializable
public abstract class ThreadLocalBufferCache<T> extends Object implements Serializable
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private ThreadLocal<T>
buffers
private int
defaultSize
-
Constructor Summary
Constructors Constructor Description ThreadLocalBufferCache(int defaultSize)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description T
getCache()
protected abstract T
newValue(int defaultSize)
void
release(T buffer)
-
-
-
Field Detail
-
buffers
private final ThreadLocal<T> buffers
-
defaultSize
private final int defaultSize
-
-