public boolean check(byte[] byteS, final int start, final int len) {
      int pos = start;
      int mark = len;
      if (len < minLen) {
        return false;
      }
      // prefix, extend start
      if (begin != null && false == begin.check(byteS, pos, mark)) {
        // no match
        return false;
      } else {
        pos += beginLen;
        mark -= beginLen;
      }
      // suffix, reduce len
      if (end != null && false == end.check(byteS, pos, mark)) {
        // no match
        return false;
      } else {
        // no pos change - no need since we've shrunk the string with same pos
        mark -= endLen;
      }
      // loop for middles
      for (int i = 0; i < middle.length; i++) {
        int index = middle[i].index(byteS, pos, mark);
        if (index == -1) {
          // no match
          return false;
        } else {
          mark -= ((index-pos) + midLens[i]);
          pos = index + midLens[i];
        }
      }
      // if all is good
      return true;
    }
Matches a chained sequence of checkers.

This has 4 chain scenarios cases in it (has no escaping or single char wildcards)

1) anchored left "abc%def%"
2) anchored right "%abc%def"
3) unanchored "%abc%def%"
4) anchored on both sides "abc%def"
ql/src/java/org/apache/hadoop/hive/ql/exec/vector/expressions/AbstractFilterStringColLikeStringScalar.java