private byte doPut( int key, byte value, int index ) { byte previous = no_entry_value; boolean isNewMapping = true; if ( index < 0 ) { index = -index -1; previous = _values[index]; isNewMapping = false; } _values[index] = value; if (isNewMapping) { postInsertHook( consumeFreeSlot ); } return previous; }
/** {@inheritDoc} */ public byte adjustOrPutValue( int key, byte adjust_amount, byte put_amount ) { int index = insertKey( key ); final boolean isNewMapping; final byte newValue; if ( index < 0 ) { index = -index -1; newValue = ( _values[index] += adjust_amount ); isNewMapping = false; } else { newValue = ( _values[index] = put_amount ); isNewMapping = true; } byte previousState = _states[index]; if ( isNewMapping ) { postInsertHook(consumeFreeSlot); } return newValue; }
private byte doPut( int key, byte value, int index ) { byte previous = no_entry_value; boolean isNewMapping = true; if ( index < 0 ) { index = -index -1; previous = _values[index]; isNewMapping = false; } _values[index] = value; if (isNewMapping) { postInsertHook( consumeFreeSlot ); } return previous; }
private byte doPut( int key, byte value, int index ) { byte previous = no_entry_value; boolean isNewMapping = true; if ( index < 0 ) { index = -index -1; previous = _values[index]; isNewMapping = false; } _values[index] = value; if (isNewMapping) { postInsertHook( consumeFreeSlot ); } return previous; }
private byte doPut( int key, byte value, int index ) { byte previous = no_entry_value; boolean isNewMapping = true; if ( index < 0 ) { index = -index -1; previous = _values[index]; isNewMapping = false; } _values[index] = value; if (isNewMapping) { postInsertHook( consumeFreeSlot ); } return previous; }
private byte doPut( int key, byte value, int index ) { byte previousState; byte previous = no_entry_value; boolean isNewMapping = true; if ( index < 0 ) { index = -index -1; previous = _values[index]; isNewMapping = false; } previousState = _states[index]; _set[index] = key; _states[index] = FULL; _values[index] = value; if (isNewMapping) { postInsertHook( previousState == FREE ); } return previous; }
/** {@inheritDoc} */ public byte adjustOrPutValue( int key, byte adjust_amount, byte put_amount ) { int index = insertKey( key ); final boolean isNewMapping; final byte newValue; if ( index < 0 ) { index = -index -1; newValue = ( _values[index] += adjust_amount ); isNewMapping = false; } else { newValue = ( _values[index] = put_amount ); isNewMapping = true; } byte previousState = _states[index]; if ( isNewMapping ) { postInsertHook(consumeFreeSlot); } return newValue; }
/** {@inheritDoc} */ public byte adjustOrPutValue( int key, byte adjust_amount, byte put_amount ) { int index = insertKey( key ); final boolean isNewMapping; final byte newValue; if ( index < 0 ) { index = -index -1; newValue = ( _values[index] += adjust_amount ); isNewMapping = false; } else { newValue = ( _values[index] = put_amount ); isNewMapping = true; } byte previousState = _states[index]; if ( isNewMapping ) { postInsertHook(consumeFreeSlot); } return newValue; }
/** {@inheritDoc} */ @Override public byte adjustOrPutValue( int key, byte adjust_amount, byte put_amount ) { int index = insertKey( key ); final boolean isNewMapping; final byte newValue; if ( index < 0 ) { index = -index -1; newValue = ( _values[index] += adjust_amount ); isNewMapping = false; } else { newValue = ( _values[index] = put_amount ); isNewMapping = true; } if ( isNewMapping ) { postInsertHook(consumeFreeSlot); } return newValue; }
/** {@inheritDoc} */ public byte adjustOrPutValue( int key, byte adjust_amount, byte put_amount ) { int index = insertionIndex( key ); final boolean isNewMapping; final byte newValue; if ( index < 0 ) { index = -index -1; newValue = ( _values[index] += adjust_amount ); isNewMapping = false; } else { newValue = ( _values[index] = put_amount ); isNewMapping = true; } byte previousState = _states[index]; _set[index] = key; _states[index] = FULL; if ( isNewMapping ) { postInsertHook(previousState == FREE); } return newValue; }