|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectkiwi.util.ResourcePool
kiwi.util.TimerPool
A concrete implementation of ResourcePool
for managing a
pool of IntervalTimer
s.
Field Summary |
Fields inherited from class kiwi.util.ResourcePool |
|
Constructor Summary | |
TimerPool(int size)
Construct a new TimerPool of the specified size. |
Method Summary | |
protected Resource |
constructResource()
Construct a new IntervalTimer . |
void |
releaseTimer(IntervalTimer timer)
Release a timer back into the pool. |
IntervalTimer |
reserveTimer()
Reserve a timer from the pool. |
Methods inherited from class kiwi.util.ResourcePool |
getAvailableResourceCount, getTotalResourceCount, getUsedResourceCount, releaseResource, reserveResource |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TimerPool(int size)
TimerPool
of the specified size.
size
- The number of IntervalTimer
s to preallocate.Method Detail |
protected Resource constructResource()
IntervalTimer
.
constructResource
in class ResourcePool
IntervalTimer
.public IntervalTimer reserveTimer()
IntervalTimer
instance.public void releaseTimer(IntervalTimer timer)
timer
- The timer to release.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |