Known Direct Subclasses
|
Class Overview
(c) 2010 Nicolas Gramlich
(c) 2011 Zynga Inc.
Summary
[Expand]
Inherited Methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
|
Public Constructors
public
GenericPool
(int pInitialSize)
public
GenericPool
(int pInitialSize, int pGrowth)
public
GenericPool
(int pInitialSize, int pGrowth, int pAvailableItemsMaximum)
Public Methods
public
synchronized
void
batchAllocatePoolItems
(int pCount)
public
synchronized
int
getAvailableItemCount
()
public
int
getAvailableItemCountMaximum
()
public
synchronized
int
getUnrecycledItemCount
()
public
synchronized
T
obtainPoolItem
()
public
synchronized
void
recyclePoolItem
(T pItem)
public
synchronized
void
shufflePoolItems
()
Protected Methods
protected
abstract
T
onAllocatePoolItem
()
protected
T
onHandleAllocatePoolItem
()
protected
void
onHandleObtainItem
(T pItem)
Parameters
pItem
| every item that was just obtained from the pool, passes this method.
|
protected
void
onHandleRecycleItem
(T pItem)
Parameters
pItem
| every item passes this method just before it gets recycled.
|