docs: public static String toJavaDatePattern(String format) {
  
          int          len = format.length();
          char         ch;
          StringBuffer sb        = new StringBuffer(len);
          Tokenizer    tokenizer = new Tokenizer();
  
          for (int i = 0; i <= len; i++) {
              ch = (i == len) ? e
                              : format.charAt(i);
  
              if (!tokenizer.next(ch, dateTokens)) {
                  int index = tokenizer.getLastMatch();
  
                  if (index >= 0) {
                      sb.setLength(sb.length() - tokenizer.length());
                      sb.append(javaDateTokens[index]);
                  }
  
                  tokenizer.reset();
  
                  if (tokenizer.isConsumed()) {
                      continue;
                  }
              }
  
              sb.append(ch);
          }
  
          sb.setLength(sb.length() - 1);
  
          String javaPattern = sb.toString();
  
          return javaPattern;
      }