Ejemplo n.º 1
0
 public PageBuilder(BufferAllocator allocator, Schema schema, PageOutput output) {
   this.allocator = allocator;
   this.output = output;
   this.schema = schema;
   this.columnOffsets = PageFormat.columnOffsets(schema);
   this.nullBitSet = new byte[PageFormat.nullBitSetSize(schema)];
   Arrays.fill(nullBitSet, (byte) -1);
   this.fixedRecordSize = PageFormat.recordHeaderSize(schema) + PageFormat.totalColumnSize(schema);
   this.nextVariableLengthDataOffset = fixedRecordSize;
   newBuffer();
 }
Ejemplo n.º 2
0
 public void flush() {
   doFlush();
   if (buffer == null) {
     newBuffer();
   }
 }