private Scan createScan(FilterList list) {
    // build start and end key for scan
    byte[] startKey = new byte[16]; // key size with four ints
    Bytes.putInt(startKey, aOffset, 1); // a=1, takes care of a = 1
    Bytes.putInt(startKey, bOffset, 11); // b=11, takes care of b > 10
    Bytes.putInt(startKey, cOffset, 91); // c=91,
    Bytes.putInt(startKey, dOffset, 1); // d=1,

    byte[] endKey = new byte[16];
    Bytes.putInt(endKey, aOffset, 1); // a=1, takes care of a = 1
    Bytes.putInt(endKey, bOffset, 20); // b=20, takes care of b < 20
    Bytes.putInt(endKey, cOffset, 100); // c=100,
    Bytes.putInt(endKey, dOffset, 1); // d=1,

    // setup scan
    Scan scan = new Scan().withStartRow(startKey).withStopRow(endKey);
    scan.setFilter(list);
    return scan;
  }
We have rows with either "abc" or "xyz". We want values which have 'y' at second position of
the string. As a result only values with "xyz" shall be returned
hbase-server/src/test/java/org/apache/hadoop/hbase/filter/TestFiltersWithBinaryComponentComparator.java