Package org.apache.johnzon.core
Class BufferStrategyFactory.ThreadLocalProvider<T>
- java.lang.Object
-
- org.apache.johnzon.core.BufferStrategyFactory.ThreadLocalProvider<T>
-
- All Implemented Interfaces:
Serializable
,BufferStrategy.BufferProvider<T>
- Direct Known Subclasses:
BufferStrategyFactory.CharBufferThreadLocalProvider
- Enclosing class:
- BufferStrategyFactory
private abstract static class BufferStrategyFactory.ThreadLocalProvider<T> extends Object implements BufferStrategy.BufferProvider<T>
-
-
Field Summary
Fields Modifier and Type Field Description private ThreadLocalBufferCache<T>
cache
-
Constructor Summary
Constructors Constructor Description ThreadLocalProvider(int size)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description T
newBuffer()
protected abstract T
newInstance(int size)
void
release(T value)
-
-
-
Field Detail
-
cache
private final ThreadLocalBufferCache<T> cache
-
-
Method Detail
-
newInstance
protected abstract T newInstance(int size)
-
newBuffer
public T newBuffer()
- Specified by:
newBuffer
in interfaceBufferStrategy.BufferProvider<T>
-
release
public void release(T value)
- Specified by:
release
in interfaceBufferStrategy.BufferProvider<T>
-
-