Class N::Pool
In: lib/glue/pool.rb
Parent: Array

Pool

Generalized object pool implementation. Implemented as a thread safe stack. Exclusive locking is needed both for push and pop.

INVESTIGATE: Could use the SizedQueue/Queue.

Methods

new   obtain   pop   push  

Included Modules

MonitorMixin

Public Class methods

Public Instance methods

Obtains an object, passes it to a block for processing and restores it to the pool.

Obtain an object from the pool.

Add, restore an object to the pool.

[Validate]