mirror of
https://github.com/OpenHFT/Chronicle-Map.git
synced 2021-09-13 01:26:12 +00:00
Use Data.equivalent() method in KeySearch.keyEquals() (because it could be specialized to perform more efficiently), and switch arguments in Data.bytesEquivalent() usages, so that the first Data instance is more likely to optimized for comparison
This commit is contained in:
@@ -84,9 +84,7 @@ public abstract class KeySearch<K> {
|
||||
}
|
||||
|
||||
boolean keyEquals(long keySize, long keyOffset) {
|
||||
return inputKey.size() == keySize &&
|
||||
BytesUtil.bytesEqual(s.segmentBS, keyOffset,
|
||||
inputKey.bytes(), inputKey.offset(), keySize);
|
||||
return inputKey.size() == keySize && inputKey.equivalent(s.segmentBS, keyOffset);
|
||||
}
|
||||
|
||||
public boolean searchStatePresent() {
|
||||
|
||||
Reference in New Issue
Block a user