public void put(final LruMapNode val) {
        final int bin = (val.hashCode() & 0xfffffff) % hashbins;
        val.nextInBin = binArray[bin];
        binArray[bin] = val;

        val.previous = mru;
        val.next = null;
        if (mru == null) {
            lru = val;
        } else {
            mru.next = val;
        }
        mru = val;
        size++;
    }
Something like LinkedHashMap, but purpose build, less dynamic and memory efficient

@author ab
main/src/main/java/cgeo/geocaching/brouter/util/LruMap.java