447383 (5) [Avatar] Offline
Is there any good reason not to change the return type of get(K key) from Result <MapEntry<K,V>> to Result<V>?
Pierre-Yves Saumont (147) [Avatar] Offline
Yes. If you get the Entry, you can get the key and/or the value from it. If you get only the value, the key is lost. If you need it later, you have to store it somewhere. As you don't know what the caller needs, it is best to offer more possibilities.
447383 (5) [Avatar] Offline