mirror of
https://github.com/OpenHFT/Chronicle-Map.git
synced 2021-09-13 01:26:12 +00:00
Select OF_4_BYTES for Byteable values. (possibly OF_8_BYTES in the future)
This commit is contained in:
@@ -764,6 +764,13 @@ class VanillaChronicleMap<K, KI, MKI extends MetaBytesInterop<K, KI>,
|
||||
|
||||
V acquire(ThreadLocalCopies copies, MKI metaKeyInterop, KI keyInterop, K key, V usingValue,
|
||||
long hash2, boolean create) {
|
||||
V v = acquire0(copies, metaKeyInterop, keyInterop, key, usingValue, hash2, false);
|
||||
if (create && v == null)
|
||||
v = acquire0(copies, metaKeyInterop, keyInterop, key, usingValue, hash2, true);
|
||||
return v;
|
||||
}
|
||||
V acquire0(ThreadLocalCopies copies, MKI metaKeyInterop, KI keyInterop, K key, V usingValue,
|
||||
long hash2, boolean create) {
|
||||
if (create)
|
||||
writeLock();
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user