@Override public void writeTo(WritableByteChannel channel, FileSmoosher smoosher) throws IOException { writer.writeTo(channel, smoosher); } }
@Override public void writeTo(WritableByteChannel channel, FileSmoosher smoosher) throws IOException { makeDelegate(); delegate.writeTo(channel, smoosher); } }
@Override public void writeTo(WritableByteChannel channel, FileSmoosher smoosher) throws IOException { SerializerUtils.writeInt(channel, Ints.checkedCast(writer.getSerializedSize())); writer.writeTo(channel, smoosher); if (!nullRowsBitmap.isEmpty()) { nullValueBitmapWriter.writeTo(channel, smoosher); } } }
writer.add(Long.parseLong(line)); writer.writeTo(output, null);
public void testValues(long[] values) throws Exception { ColumnarLongsSerializer serializer = CompressionFactory.getLongSerializer( new OffHeapMemorySegmentWriteOutMedium(), "test", order, encodingStrategy, compressionStrategy ); serializer.open(); for (long value : values) { serializer.add(value); } Assert.assertEquals(values.length, serializer.size()); final ByteArrayOutputStream baos = new ByteArrayOutputStream(); serializer.writeTo(Channels.newChannel(baos), null); Assert.assertEquals(baos.size(), serializer.getSerializedSize()); CompressedColumnarLongsSupplier supplier = CompressedColumnarLongsSupplier.fromByteBuffer(ByteBuffer.wrap(baos.toByteArray()), order); ColumnarLongs longs = supplier.get(); assertIndexMatchesVals(longs, values); longs.close(); }
serializer.writeTo(Channels.newChannel(baos), null); Assert.assertEquals(baos.size(), serializer.getSerializedSize()); CompressedColumnarLongsSupplier supplier = CompressedColumnarLongsSupplier
@Override public void writeTo(WritableByteChannel channel, FileSmoosher smoosher) throws IOException { writer.writeTo(channel, smoosher); } }
@Override public void writeTo(WritableByteChannel channel, FileSmoosher smoosher) throws IOException { makeDelegate(); delegate.writeTo(channel, smoosher); } }
@Override public void writeTo(WritableByteChannel channel, FileSmoosher smoosher) throws IOException { SerializerUtils.writeInt(channel, Ints.checkedCast(writer.getSerializedSize())); writer.writeTo(channel, smoosher); if (!nullRowsBitmap.isEmpty()) { nullValueBitmapWriter.writeTo(channel, smoosher); } } }