public ShrunkenDictionary<T> build(ValueSerializer<T> valueSerializer) { return new ShrunkenDictionary<>(valueSerializer, fullDict.getMinId(), fullDict.getMaxId(), fullDict.getSizeOfId(), fullDict.getSizeOfValue(), valueToIdMap); } }
while (sourceDict.getSizeOfValue() > newKeyBodyBuf.length - bufOffset || // mergedDict.getSizeOfValue() > newKeyBodyBuf.length - bufOffset || // mergedDict.getSizeOfId() > newKeyBodyBuf.length - bufOffset) { byte[] oldBuf = newKeyBodyBuf;
@Override public boolean moveNext() throws IOException { if (curDictIndex < dictionaryList.size() && curKey <= curDict.getMaxId()) { byte[] buffer = new byte[curDict.getSizeOfValue()]; int size = curDict.getValueBytesFromId(curKey, buffer, 0); curValue = Bytes.copy(buffer, 0, size); if (++curKey > curDict.getMaxId()) { if (++curDictIndex < dictionaryList.size()) { curDict = dictionaryList.get(curDictIndex); curKey = curDict.getMinId(); } } return true; } curValue = null; return false; }
public ShrunkenDictionary<T> build(ValueSerializer<T> valueSerializer) { return new ShrunkenDictionary<>(valueSerializer, fullDict.getMinId(), fullDict.getMaxId(), fullDict.getSizeOfId(), fullDict.getSizeOfValue(), valueToIdMap); } }
Dictionary<?> mergedDict = dictMgr.getDictionary(mergedCubeSegment.getDictResPath(col)); while (sourceDict.getSizeOfValue() > newKeyBuf.length - bufOffset || mergedDict.getSizeOfValue() > newKeyBuf.length - bufOffset) { byte[] oldBuf = newKeyBuf; newKeyBuf = new byte[2 * newKeyBuf.length];
while (sourceDict.getSizeOfValue() > newKeyBodyBuf.length - bufOffset || // mergedDict.getSizeOfValue() > newKeyBodyBuf.length - bufOffset || // mergedDict.getSizeOfId() > newKeyBodyBuf.length - bufOffset) { byte[] oldBuf = newKeyBodyBuf;