public int getInt(final long key) {
        // bit-stats on first get
        if (getCount++ == 0L) {
            System.out.println("**** DenseLongMap stats ****");
            System.out.println("putCount=" + putCount);
            for (int i = 0; i < 8; i++) {
                System.out.println(i + "-bitplanes=" + bitplaneCount[i]);
            }
            System.out.println("****************************");
        }

    /* actual stats for the 30x45 raster and 512 blocksize with filtered nodes:
     *
     **** DenseLongMap stats ****
     putCount=858518399
     0-bitplanes=783337
     1-bitplanes=771490
     2-bitplanes=644578
     3-bitplanes=210767
     4-bitplanes=439
     5-bitplanes=0
     6-bitplanes=0
     7-bitplanes=0
     *
     * This is a total of 1,2 GB
     * (1.234.232.832+7.381.126+15.666.740 for body/header/object-overhead )
    */

        if (key < 0) {
            return -1;
        }
        final int blockn = (int) (key >> blocksizeBits);
        final int offset = (int) (key & blocksizeBitsMask);

        final byte[] block = blockn < blocklist.size() ? blocklist.get(blockn) : null;

        if (block == null) {
            return -1;
        }

        // check how many bitplanes we have from the arrayzize
        int valuebits = 1;
        while (sizeForBits(valuebits) < block.length) {
            valuebits++;
        }
        final int headersize = 1 << valuebits;

        final int bitmask = 1 << (offset & 7);
        int probebit = 1;
        int blockidx = (offset >> 3) + headersize;
        int idx = 0; // 0 is reserved (=unset)

        for (int i = 0; i < valuebits; i++) {
            if ((block[blockidx] & bitmask) != 0) {
                idx |= probebit;
            }
            probebit <<= 1;
            blockidx += blocksize;
        }

        // lookup that value in the lookup header
        return ((256 + block[idx]) & 0xff) - 1;
    }
Creates a DenseLongMap for the given block size

@param blocksize bytes per bit-plane
main/src/main/java/cgeo/geocaching/brouter/util/DenseLongMap.java