private static @NotNull List<FileNameMatcher> parse(@NotNull Object context,
                                                      @NotNull String semicolonDelimitedTokens,
                                                      @NotNull Function<? super String, ? extends FileNameMatcher> matcherFactory) {
    if (semicolonDelimitedTokens.isEmpty()) {
      return Collections.emptyList();
    }

    StringTokenizer tokenizer = new StringTokenizer(semicolonDelimitedTokens, FileTypeConsumer.EXTENSION_DELIMITER, false);
    List<FileNameMatcher> list = new ArrayList<>(StringUtil.countChars(semicolonDelimitedTokens, ';')+1);
    while (tokenizer.hasMoreTokens()) {
      String ext = tokenizer.nextToken().trim();
      if (ext.isEmpty()) {
        throw new InvalidDataException("Token must not be empty but got: '"+semicolonDelimitedTokens+"' in "+context);
      }
      list.add(matcherFactory.apply(ext));
    }
    return list;
  }
private static @NotNull List<FileNameMatcher> parse(@NotNull Object context,
                                                      @NotNull String semicolonDelimitedTokens,
                                                      @NotNull Function<? super String, ? extends FileNameMatcher> matcherFactory)