|
XNIO API 2.1.0.CR2 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
T - the resource typepublic interface Pool<T>

A generic pooled resource manager.
| Method Summary | |
|---|---|
T |
allocate()
Allocate a resource from the pool, or null if none are available. |
void |
discard(T resource)
Discard a "damaged" resource. |
void |
free(T resource)
Free a pooled resource. |
| Method Detail |
|---|
T allocate()
null if none are available.
null if none are available
void free(T resource)
throws IllegalArgumentException
resource - the resource to re-pool
IllegalArgumentException - if the given resource does not belong in this poolvoid discard(T resource)
resource - the resource to discard
|
XNIO API 2.1.0.CR2 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||