docs: private static Object parse(String line) {
          StringTokenizer tokenizer = new StringTokenizer(line);
          if (tokenizer.hasMoreTokens()) {
              String token = tokenizer.nextToken();
              if (token.equals("RewriteCond")) {
                  // RewriteCond TestString CondPattern [Flags]
                  RewriteCond condition = new RewriteCond();
                  if (tokenizer.countTokens() < 2) {
                      throw UndertowServletLogger.ROOT_LOGGER.invalidRewriteConfiguration(line);
                  }
                  condition.setTestString(tokenizer.nextToken());
                  condition.setCondPattern(tokenizer.nextToken());
                  if (tokenizer.hasMoreTokens()) {
                      String flags = tokenizer.nextToken();
                      if (flags.startsWith("[") && flags.endsWith("]")) {
                          flags = flags.substring(1, flags.length() - 1);
                      }
                      StringTokenizer flagsTokenizer = new StringTokenizer(flags, ",");
                      while (flagsTokenizer.hasMoreElements()) {
                          parseCondFlag(line, condition, flagsTokenizer.nextToken());
                      }
                  }
                  return condition;
              } else if (token.equals("RewriteRule")) {
                  // RewriteRule Pattern Substitution [Flags]
                  RewriteRule rule = new RewriteRule();
                  if (tokenizer.countTokens() < 2) {
                      throw UndertowServletLogger.ROOT_LOGGER.invalidRewriteConfiguration(line);
                  }
                  rule.setPatternString(tokenizer.nextToken());
                  rule.setSubstitutionString(tokenizer.nextToken());
                  if (tokenizer.hasMoreTokens()) {
                      String flags = tokenizer.nextToken();
                      if (flags.startsWith("[") && flags.endsWith("]")) {
                          flags = flags.substring(1, flags.length() - 1);
                      }
                      StringTokenizer flagsTokenizer = new StringTokenizer(flags, ",");
                      while (flagsTokenizer.hasMoreElements()) {
                          parseRuleFlag(line, rule, flagsTokenizer.nextToken());
                      }
                  }
                  return rule;
              } else if (token.equals("RewriteMap")) {
                  // RewriteMap name rewriteMapClassName whateverOptionalParameterInWhateverFormat
                  if (tokenizer.countTokens() < 2) {
                      throw UndertowServletLogger.ROOT_LOGGER.invalidRewriteConfiguration(line);
                  }
                  String name = tokenizer.nextToken();
                  String rewriteMapClassName = tokenizer.nextToken();
                  RewriteMap map = null;
                  try {
                      map = (RewriteMap) (Class.forName(rewriteMapClassName).newInstance());
                  } catch (Exception e) {
                      throw UndertowServletLogger.ROOT_LOGGER.invalidRewriteMap(rewriteMapClassName);
                  }
                  if (tokenizer.hasMoreTokens()) {
                      map.setParameters(tokenizer.nextToken());
                  }
                  Object[] result = new Object[2];
                  result[0] = name;
                  result[1] = map;
                  return result;
              } else if (token.startsWith("#")) {
                  // it's a comment, ignore it
              } else {
                  throw UndertowServletLogger.ROOT_LOGGER.invalidRewriteConfiguration(line);
              }
          }
          return null;
      }