Datastructure: Pool.
A generic class for handling pools of objects that is more efficient than
goog.structs.Pool because it doesn't maintain a list of objects that are in
use. See constructor comment.
A generic pool class. Simpler and more efficient than goog.structs.Pool
because it doesn't maintain a list of objects that are in use. This class
has constant overhead and doesn't create any additional objects as part of
the pool management after construction time.
IMPORTANT: If the objects being pooled are arrays or maps that can have
unlimited number of properties, they need to be cleaned before being
returned to the pool.
Also note that {@see goog.object.clean} actually allocates an array to clean
the object passed to it, so simply using this function would defy the
purpose of using the pool.