@@ -65,7 +65,7 @@ and enters it into this map unless null.
65
65
**returns** the current (existing or computed) value associated with
66
66
the specified key, or null if the computed value is null
67
67
68
- **Remark**: putIfAbsent(1, null) will NOT add an entry (supposing 1 is absent)
68
+ **Remark**: ` putIfAbsent(1, null)` will NOT add an entry (supposing 1 is absent)
69
69
70
70
* ` putIfAbsent ` vs ` computeIfAbsent ` : [ stackoverflow differences] ( https://stackoverflow.com/a/48184207 )
71
71
* different returns,
@@ -81,6 +81,8 @@ Replaces each entry's value with the result of invoking the given
81
81
function on that entry until all entries have been processed or the
82
82
function throws an exception
83
83
84
+ **Remark**: Can't change the element type. To do that - use a stream.
85
+
84
86
* ` default boolean replace(K key, V oldValue, V newValue) ` - Replaces the
85
87
entry for the specified key only if currently mapped to the specified value.
86
88
* ` default V replace(K key, V value) ` - Replaces the entry for the
0 commit comments