class KeyValueStoreFile implements Closeable {

    static void readKeyValuePair( PageCursor cursor, int offset, WritableBuffer key, WritableBuffer value )
            throws IOException
    {
        long retriesLeft = MAX_LOOKUP_RETRY_COUNT;
        do
        {
            cursor.setOffset( offset );
            key.getFrom( cursor );
            value.getFrom( cursor );
        }
        while ( cursor.shouldRetry() && (--retriesLeft) > 0 );

        if ( cursor.checkAndClearBoundsFlag() )
        {
            throwOutOfBounds( cursor, offset );
        }

        if ( retriesLeft == 0 )
        {
            throwFailedRead( cursor, offset );
        }
    }

      KeyValueStoreFile( PagedFile file, int keySize, int valueSize, Metadata metadata );

}