commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <>
Subject Re: [collections] unclear contract for LRUMap.setMaximumSize(int)
Date Wed, 20 Feb 2002 03:49:13 GMT

----- Original Message -----
From: "Morgan Delagrange" <>
> Hi all,
> This is strange.  What is the proper behaviour of the
> LRUMap.setMaximumSize(int) method, do you think?  One would assume that,
> the current LRUMap has more keys than the new maximum size, the LRUMap
> trim excess keys according to the LRU algorithm.  But right now, all it
> appears to do is maintain the current size.  The Javadocs do not indicate
> one way or the other.

I guess since its vague right now this could go either way :)

My gut feel is with the former, that the map shrinks if the new max size is
smaller than the currrent size.


To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message