protected class ConcurrentReferenceHashMap.WriteThroughEntry extends SimpleEntry
Custom Entry class used by EntryIterator.next(), that relays setValue changes to the underlying map.
Constructor and description |
---|
protected WriteThroughEntry(K k, V v) |
Type Params | Return Type | Name and description |
---|---|---|
|
public V |
setValue(V value) Set our entry's value and writes it through to the map. |
Set our entry's value and writes it through to the map. The value to return is somewhat arbitrary: since a WriteThroughEntry does not necessarily track asynchronous changes, the most recent "previous" value could be different from what we return (or could even have been removed in which case the put will re-establish). We do not and cannot guarantee more.
Copyright © 2003-2024 The Apache Software Foundation. All rights reserved.