commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Neidhart (JIRA)" <>
Subject [jira] [Commented] (COLLECTIONS-467) LRUMap remove callback
Date Mon, 13 May 2013 22:27:17 GMT


Thomas Neidhart commented on COLLECTIONS-467:

You may take a look at the PassiveExpiringMap decorator which has been added recently to the

For the other things, patches are, as always, very welcome. Regarding the callback, what do
you think about a listener interface? Callbacks as protected methods always require subclassing,
which may not always be useful / possible.
> LRUMap remove callback
> ----------------------
>                 Key: COLLECTIONS-467
>                 URL:
>             Project: Commons Collections
>          Issue Type: New Feature
>    Affects Versions: 3.2
>            Reporter: l0co
>            Priority: Minor
>             Fix For: 4.x
> If you use LRUMap with objects that require doing some disposal when they are dropped
(eg. close()) and you hold these objects only in LRUMap, you cannot do it with current implementation.
I propose to add onRemove() and onAdd() methods to the implementation, so that you can create
anonymous inherited class and be able to react to these events.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message