@Override public ColumnarMultiInts get() { return new CompressedVSizeColumnarMultiIntsSupplier.CompressedVSizeColumnarMultiInts( offsetSupplier.get(), valueSupplier.get() ); }
private void makeWithSerde(final int chunkSize) throws IOException { CloseQuietly.close(columnarInts); ByteArrayOutputStream baos = new ByteArrayOutputStream(); final CompressedColumnarIntsSupplier theSupplier = CompressedColumnarIntsSupplier.fromIntBuffer( IntBuffer.wrap(vals), chunkSize, ByteOrder.nativeOrder(), compressionStrategy, closer ); theSupplier.writeTo(Channels.newChannel(baos), null); final byte[] bytes = baos.toByteArray(); Assert.assertEquals(theSupplier.getSerializedSize(), bytes.length); supplier = CompressedColumnarIntsSupplier.fromByteBuffer(ByteBuffer.wrap(bytes), ByteOrder.nativeOrder()); columnarInts = supplier.get(); }
byteOrder ); ColumnarInts columnarInts = supplierFromByteBuffer.get(); assertEquals(vals.length, columnarInts.size()); for (int i = 0; i < vals.length; ++i) {
private void setupSimple(final int chunkSize) { CloseQuietly.close(columnarInts); vals = new int[]{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16}; supplier = CompressedColumnarIntsSupplier.fromIntBuffer( IntBuffer.wrap(vals), chunkSize, ByteOrder.nativeOrder(), compressionStrategy, closer ); columnarInts = supplier.get(); }
final ColumnarInts columnarInts2 = supplier.get(); try { new Thread(new Runnable()
byteOrder ); ColumnarInts columnarInts = supplierFromByteBuffer.get(); assertEquals(vals.length, columnarInts.size()); for (int i = 0; i < vals.length; ++i) {
@Override public ColumnarMultiInts get() { return new CompressedVSizeColumnarMultiIntsSupplier.CompressedVSizeColumnarMultiInts( offsetSupplier.get(), valueSupplier.get() ); }