@Override public void putNormalizedKey(DoubleValue record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(FloatValue record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@SuppressWarnings("unchecked") private <T extends Comparable<T>> void assertNormalizableKey(NormalizableKey<T> key1, NormalizableKey<T> key2, int len) { byte[] normalizedKeys = new byte[32]; MemorySegment wrapper = MemorySegmentFactory.wrap(normalizedKeys); key1.copyNormalizedKey(wrapper, 0, len); key2.copyNormalizedKey(wrapper, len, len); for (int i = 0; i < len; i++) { int comp; int normKey1 = normalizedKeys[i] & 0xFF; int normKey2 = normalizedKeys[len + i] & 0xFF; if ((comp = (normKey1 - normKey2)) != 0) { if (Math.signum(key1.compareTo((T) key2)) != Math.signum(comp)) { Assert.fail("Normalized key comparison differs from actual key comparision"); } return; } } if (key1.compareTo((T) key2) != 0 && key1.getMaxNormalizedKeyLen() <= len) { Assert.fail("Normalized key was not able to distinguish keys, " + "although it should as the length of it sufficies to uniquely identify them"); } }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(FloatValue record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(DoubleValue record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(DoubleValue record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(FloatValue record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }
@Override public void putNormalizedKey(T record, MemorySegment target, int offset, int numBytes) { NormalizableKey<?> key = (NormalizableKey<?>) record; key.copyNormalizedKey(target, offset, numBytes); }