code: public List<K> getKeysSortedByValue( final Comparator<V> comparator ) {
          synchronized ( _map ) {
              @SuppressWarnings( "unchecked" )
              final
              Entry<K, ManagedItem<V>>[] a = _map.entrySet().toArray( new Map.Entry[_map.size()] );
              final Comparator<Entry<K, ManagedItem<V>>> c = new Comparator<Entry<K, ManagedItem<V>>>() {
  
                  @Override
                  public int compare( final Entry<K, ManagedItem<V>> o1, final Entry<K, ManagedItem<V>> o2 ) {
                      return comparator.compare( o1.getValue()._value, o2.getValue()._value );
                  }
  
              };
              Arrays.sort(a, c);
              return new LRUCache.ArrayList<K, V>( a );
          }
      }
docs: The keys sorted by the given value comparator.
  
  @return the underlying set, see {@link LinkedHashMap#keySet()}.