code: public static int findByte(byte [] utf, int start, int end, byte b) {
      for(int i=start; i<end; i++) {
        if (utf[i]==b) {
          return i;
        }
      }
      return -1;      
    }
docs: Find the first occurrence of the given byte b in a UTF-8 encoded string
  @param utf a byte array containing a UTF-8 encoded string
  @param start starting offset
  @param end ending position
  @param b the byte to find
  @return position that first byte occures otherwise -1