-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathConfig.cs
38 lines (34 loc) · 1.32 KB
/
Config.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
namespace ImageQuantization
{
public class Config
{
public static bool AUTOTEST = false;
public const bool BOUNS = false;
public const string dashes = "--------------------------------------------------------------------------------\n";
public static string GetTestCaseResultString(string currImageName, string distinctColorsTextBox, string mst_sum_text_box, string totalTimeTextBox, string numOfClustersTextBox)
{
string testCaseResult = "Image name: " + currImageName + "\nNumber of distinct colors: " + distinctColorsTextBox + "\nMST sum: " + mst_sum_text_box + "\nTotal time: " + totalTimeTextBox + "\nCaluculated number of clusters: " + numOfClustersTextBox + "\n\n";
return testCaseResult;
}
public static void VerifyOutputDirExistEmpty()
{
if (!Directory.Exists(Paths.outputPath))
{
Directory.CreateDirectory(Paths.outputPath);
}
else
{
string[] files = Directory.GetFiles(Paths.outputPath);
foreach (string file in files)
{
File.Delete(file);
}
}
}
}
}