private boolean isIso8601Delimiter(String candidate) {
    return candidate.length() == 1 && VALID_ISO_8601_DELIMITERS.contains(candidate);
  }
Parse pattern to list of tokens.
common/src/java/org/apache/hadoop/hive/common/format/datetime/HiveSqlDateTimeFormatter.java