src/main/java/org/nustaq/offheap/FSTBinaryOffheapMap.java
public BytezByteSource getBinary( ByteSource key ) {
        checkThread();
        if ( key.length() != keyLen )
            throw new RuntimeException("key must have length "+keyLen);
        long aLong = index.get(key);
        if ( aLong == 0 ) {
            return null;
        }
        long off = aLong;
        int len = getContentLenFromHeader(off);
        off+= getHeaderLen();
        tmpValueBytez.setLen(len);
        tmpValueBytez.setOff(off);
        return tmpValueBytez;
    }
public BytezByteSource getBinary( ByteSource key ) {
        checkThread();
        if ( key.length() != keyLen )
            throw new RuntimeException("key must have length "+keyLen);
        long aLong = index.get(key);
        if ( aLong == 0 ) {
            return null;
        }
        long off = aLong;
        int len = getContentLenFromHeader(off);
        off+= getHeaderLen();
        tmpValueBytez.setLen(len);
        tmpValueBytez.setOff(off);
        return tmpValueBytez;
    }
public BytezByteSource getBinary ( ByteSource key ) { checkThread ( ) ; if ( key . length ( ) != keyLen ) throw new RuntimeException ( "key must have length " + keyLen ) ; long aLong = index . get ( key ) ; if ( aLong == 0 ) { return null ; } long off = aLong ; int len = getContentLenFromHeader ( off ) ; off += getHeaderLen ( ) ; tmpValueBytez . setLen ( len ) ; tmpValueBytez . setOff ( off ) ; return tmpValueBytez ; }
get an entry. the returned ByteSource must be processed immediately as it will be reused
internally on next get
Warning: Concurrent Modification (e.g. add remove elements during iteration) is NOT SUPPORTED
and NOT CHECKED. Collect keys to change inside iteration and perform changes after iteration is
finished.
@param key
@return
get an entry . the returned ByteSource must be processed immediately as it will be reused internally on next get Warning : Concurrent Modification ( e . g . add remove elements during iteration ) is NOT SUPPORTED and NOT CHECKED . Collect keys to change inside iteration and perform changes after iteration is finished .