суммарное число задач, и время пакетов при экспорте

This commit is contained in:
2023-12-09 22:47:15 +03:00
parent dbd8d416f9
commit fce85afc71
5 changed files with 77 additions and 46 deletions

View File

@@ -1095,10 +1095,10 @@ public class Utils {
state = TaskState.WrongTestFormat;
} else if (errors > 0) {
state = TaskState.DoneWithErrors;
}else {
} else {
state = TaskState.Done;
}
return new Pair<>( state, (int) ((((double) complete) / total) * 100));
return new Pair<>(state, (int) ((((double) complete) / total) * 100));
}
public static Pair<TaskState, Integer> analyzePerformance(List<String> lines) {
StringTemplate stringTemplate = new StringTemplate("Verification =", "");
@@ -1144,5 +1144,15 @@ public class Utils {
public static boolean isVersion(File directory) throws Exception {
return new File(directory, Constants.data).exists();
}
public static String printSplittedDateInterval(long milliseconds) {
//--
long seconds = milliseconds / 1000;
long hours = seconds / 3600;
seconds = seconds - hours * 3600;
long minutes = (seconds) / 60;
seconds = seconds - minutes * 60;
//--
return hours + " часов, " + minutes + " минут, " + seconds + " секунд";
}
}