private byte[] toBinary(byte[] value, int max, boolean end, boolean nextBA) {
    byte[] bytes = new byte[max + 1];
    System.arraycopy(value, 0, bytes, 0, Math.min(value.length, max));
    if (end) {
      Arrays.fill(bytes, value.length, max, (byte) 0xff);
    }
    if (nextBA) {
      bytes[max] = 0x01;
    }
    return bytes;
  }
Simple extension of {@link SampleHBaseKeyFactory2} with exception of using filters instead of start
and stop keys
hbase-handler/src/test/org/apache/hadoop/hive/hbase/SampleHBaseKeyFactory3.java