You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by "Nair, Anand" <AN...@ea.com> on 2005/01/19 00:23:54 UTC

Looking for WHEN_POOLSIZEMAX_BLOCK

Hello,

 

There does not seem to an API which can determine the collective size of
the commons collection pool. What I am looking for is a way to tell the
factory block until the collection size goes below a threshold value.
Basically I am interested in heap size consumed by the pool , since
there is not a good way to figure that out in java ,  I guess it would
be helpful if there is a way we can associate size of the object to the
pooled object so that factory framework can figure that out. Something
like

 

Class MyObject implements MemorySizable{

{

            //Estimated size of the object

            Int size_in_bytes  = 8;

 

            Public int getSizeinBytes()

            {

                        Return size_in_bytes;

            }

}

 

Let me know if you have any suggestions or I missed something which can
provide me the functionality.

 

Thanks

Anand