1 Reply Latest reply on Apr 7, 2013 1:01 AM by jtahlborn

    Shouldn't LinkedHashSet have removeEldestEntry like LinkedHashMap


      Would it be useful if LinkedHashSet, like LinkedHashMap, had the option of overriding a removeEldestEntry method called every time elements are added to the collection.

      I think this would be useful to function as a BoundBufferQueue
      -Bound -Fixed size
      -Buffer -When full and new elements added, the eldest element is dicarded
      -Queue -FIFO Queue or Deque

      Can anybody recommend a collection in the framework that can serve this kind of purpose?
      If not, does this sound like it would be a helpful addition?