/** {@inheritDoc} */ @Override public V putIfAbsent(final float k, final V v) { final int pos = find(k); if (pos >= 0) return value[pos]; insert(-pos - 1, k, v); return defRetValue; } /** {@inheritDoc} */
@Override public V put(final float k, final V v) { final int pos = find(k); if (pos < 0) { insert(-pos - 1, k, v); return defRetValue; } final V oldValue = value[pos]; value[pos] = v; return oldValue; } /**
/** {@inheritDoc} */ @Override public V computeIfAbsent(final float k, final java.util.function.DoubleFunction<? extends V> mappingFunction) { java.util.Objects.requireNonNull(mappingFunction); final int pos = find(k); if (pos >= 0) return value[pos]; final V newValue = mappingFunction.apply(k); insert(-pos - 1, k, newValue); return newValue; } /** {@inheritDoc} */
/** {@inheritDoc} */ @Override public V compute(final float k, final java.util.function.BiFunction<? super Float, ? super V, ? extends V> remappingFunction) { java.util.Objects.requireNonNull(remappingFunction); final int pos = find(k); final V newValue = remappingFunction.apply(Float.valueOf(k), pos >= 0 ? (value[pos]) : null); if (newValue == null) { if (pos >= 0) { if ((Float.floatToIntBits(k) == 0)) removeNullEntry(); else removeEntry(pos); } return defRetValue; } V newVal = (newValue); if (pos < 0) { insert(-pos - 1, k, newVal); return newVal; } return value[pos] = newVal; } /** {@inheritDoc} */
/** {@inheritDoc} */ @Override public V merge(final float k, final V v, final java.util.function.BiFunction<? super V, ? super V, ? extends V> remappingFunction) { java.util.Objects.requireNonNull(remappingFunction); final int pos = find(k); if (pos < 0 || value[pos] == null) { if (v == null) return defRetValue; insert(-pos - 1, k, v); return v; } final V newValue = remappingFunction.apply((value[pos]), (v)); if (newValue == null) { if ((Float.floatToIntBits(k) == 0)) removeNullEntry(); else removeEntry(pos); return defRetValue; } return value[pos] = (newValue); } /*