public void fetchNext(GTRecord result) { if (hasNext() == false) throw new IllegalArgumentException(); for (int i = 0; i < selectedColBlocks.trueBitCount(); i++) { int c = selectedColBlocks.trueBitAt(i); result.loadCellBlock(c, cellBlockBuffers[c]); } cur++; } }
private void loadRecord(Result r) { Cell[] cells = r.rawCells(); Cell cell = cells[0]; if (Bytes.compareTo(CF_B, 0, CF_B.length, cell.getFamilyArray(), cell.getFamilyOffset(), cell.getFamilyLength()) != 0 // || Bytes.compareTo(COL_B, 0, COL_B.length, cell.getQualifierArray(), cell.getQualifierOffset(), cell.getQualifierLength()) != 0) throw new IllegalStateException(); rec.loadCellBlock(0, ByteBuffer.wrap(cell.getRowArray(), cell.getRowOffset() + ID_LEN, cell.getRowLength() - ID_LEN)); rec.loadCellBlock(1, ByteBuffer.wrap(cell.getValueArray(), cell.getValueOffset(), cell.getValueLength())); }
public void fetchNext(GTRecord result) { if (hasNext() == false) throw new IllegalArgumentException(); for (int i = 0; i < selectedColBlocks.trueBitCount(); i++) { int c = selectedColBlocks.trueBitAt(i); result.loadCellBlock(c, cellBlockBuffers[c]); } cur++; } }
private void loadRecord(Result r) { Cell[] cells = r.rawCells(); Cell cell = cells[0]; if (Bytes.compareTo(CF_B, 0, CF_B.length, cell.getFamilyArray(), cell.getFamilyOffset(), cell.getFamilyLength()) != 0 // || Bytes.compareTo(COL_B, 0, COL_B.length, cell.getQualifierArray(), cell.getQualifierOffset(), cell.getQualifierLength()) != 0) throw new IllegalStateException(); rec.loadCellBlock(0, ByteBuffer.wrap(cell.getRowArray(), cell.getRowOffset() + ID_LEN, cell.getRowLength() - ID_LEN)); rec.loadCellBlock(1, ByteBuffer.wrap(cell.getValueArray(), cell.getValueOffset(), cell.getValueLength())); }