src/main/java/com/stoyanr/evictor/queue/NavigableMapEvictionQueue.java
/**
     * {@inheritDoc}
     * 
     * <p>
     * This implementation uses the <tt>headMap</tt> method on the map to find
     * all entries that should be evicted, and then calls the <tt>evict</tt>
     * method on each one of them and removes them from the map.
     * </p>
     */



This implementation uses the headMap method on the map to find
all entries that should be evicted, and then calls the evict
method on each one of them and removes them from the map.
This implementation uses the headMap method on the map to find all entries that should be evicted and then calls the evict method on each one of them and removes them from the map .
@Override
    public boolean evictEntries() {
        boolean result = false;
        ConcurrentNavigableMap<Long, EvictibleEntry<K, V>> head = map.headMap(System.nanoTime());
        if (!head.isEmpty()) {
            for (EvictibleEntry<K, V> e : head.values()) {
                e.evict(false);
            }
            head.clear();
            result = true;
        }
        return result;
    }
@ Override public boolean evictEntries ( ) { boolean result = false ; ConcurrentNavigableMap < Long , EvictibleEntry < K , V > > head = map . headMap ( System . nanoTime ( ) ) ; if ( ! head . isEmpty ( ) ) { for ( EvictibleEntry < K , V > e : head . values ( ) ) { e . evict ( false ) ; } head . clear ( ) ; result = true ; } return result ; }
{@inheritDoc}
{ @inheritDoc }