public static void appendCertificates(@NotNull String alias, @NotNull Collection<? extends Certificate> certificates) {
    int i = 0;
    for (Certificate certificate : certificates) {
      appendCertificate(i == 0 ? alias : alias + "-" + i, certificate);
      ++i;
    }
  }
public static void appendCertificates(@NotNull String alias, @NotNull Collection<? extends Certificate> certificates)