public void writeNull() { vector.setNull(idx()); vector.setValueCount(idx()+1); } }
static void populate(VarBinaryVector vector, byte[][] values){ vector.allocateNew(); Random r = new Random(); for(int i =0; i < values.length; i++){ byte[] val = values[i]; if(val != null){ vector.setSafe(i, val, 0, val.length); } else { // add noise. this confirms that after pivot, noise is gone. byte[] bytes = new byte[r.nextInt(15)]; r.nextBytes(bytes); vector.setSafe(i, bytes, 0, bytes.length); vector.setNull(i); } } vector.setValueCount(values.length); }
); colVarBinaryV.set(2, "long long long long value".getBytes()); colVarBinaryV.setNull(3); colVarBinaryV.set(4, "l".getBytes());