Code tidy after code inspections

This commit is contained in:
Peter Lawrey
2018-04-21 17:41:31 +01:00
parent 9323cf28a7
commit e7c7dd8975
9 changed files with 23 additions and 31 deletions
@@ -373,13 +373,16 @@ public abstract class VanillaChronicleHash<K,
private void initOwnTransients() {
globalMutableState = createGlobalMutableState();
tierBulkOffsets = new ArrayList<>();
if (tierHashLookupSlotSize == 4) {
hashLookup = new IntCompactOffHeapLinearHashTable(this);
} else if (tierHashLookupSlotSize == 8) {
hashLookup = new LongCompactOffHeapLinearHashTable(this);
} else {
throw new AssertionError("hash lookup slot size could be 4 or 8, " +
tierHashLookupSlotSize + " observed");
switch (tierHashLookupSlotSize) {
case 4:
hashLookup = new IntCompactOffHeapLinearHashTable(this);
break;
case 8:
hashLookup = new LongCompactOffHeapLinearHashTable(this);
break;
default:
throw new AssertionError("hash lookup slot size could be 4 or 8, " +
tierHashLookupSlotSize + " observed");
}
identity = new Identity();
}