public static void printClassesList(List<String> classNames, String packageName, String category, String filters, File tempFile)
    throws IOException {

    try (PrintWriter writer = new PrintWriter(new OutputStreamWriter(new FileOutputStream(tempFile), StandardCharsets.UTF_8))) {
      writer.println(packageName); //package name
      writer.println(category); //category
      writer.println(filters); //patterns
      for (String name : classNames) {
        writer.println(name);
      }
    }
  }
public static void printClassesList(List<String> classNames, String packageName, String category, String filters, File tempFile)