Compare commits
2 Commits
84cc5f0778
...
d5b9af541f
Author | SHA1 | Date | |
---|---|---|---|
d5b9af541f | |||
52e65ac1ed |
@@ -23,7 +23,7 @@ namespace Elwig.Helpers {
|
|||||||
|
|
||||||
if (ini == null || !ini.TryGetKey("database.file", out string db)) {
|
if (ini == null || !ini.TryGetKey("database.file", out string db)) {
|
||||||
DatabaseFile = App.DataPath + "database.sqlite3";
|
DatabaseFile = App.DataPath + "database.sqlite3";
|
||||||
} else if (db.Length > 1 && db[1] == ':') {
|
} else if (db.Length > 1 && (db[1] == ':' || db[0] == '/' || db[0] == '\\')) {
|
||||||
DatabaseFile = db;
|
DatabaseFile = db;
|
||||||
} else {
|
} else {
|
||||||
DatabaseFile = App.DataPath + db;
|
DatabaseFile = App.DataPath + db;
|
||||||
|
@@ -1,47 +0,0 @@
|
|||||||
namespace Elwig.Helpers {
|
|
||||||
// 1 °KMW =
|
|
||||||
// 1 °NM = kg/100L = 10g/L
|
|
||||||
// 1 °Oe =
|
|
||||||
// 1 °Bé =
|
|
||||||
// 1 °Bx = g/100g (x Gramm Zucker pro 100 Gramm Flüssigkeit)
|
|
||||||
internal class Gradation {
|
|
||||||
/// <summary>
|
|
||||||
/// Gradation in mg/L.
|
|
||||||
/// </summary>
|
|
||||||
uint mgpl;
|
|
||||||
|
|
||||||
public Gradation(uint mgpl) {
|
|
||||||
this.mgpl = mgpl;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static double relativeDensity(double todo) {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static double KmwToOe(double kmw) {
|
|
||||||
return 0; // TODO
|
|
||||||
}
|
|
||||||
|
|
||||||
public static double OeToKmw(double oe) {
|
|
||||||
return 0; // TODO
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Gradation FromKmw(double kwm) {
|
|
||||||
return new Gradation(0); // TODO
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Gradation FromKmw(double kmw, double t) {
|
|
||||||
// The temperature can be ignored, because no volumetric unit is involved.
|
|
||||||
// 1 °KMW = 1g/100g
|
|
||||||
return FromKmw(kmw);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Gradation FromOe(double oe) {
|
|
||||||
return new Gradation(0); // TODO
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Gradation FromOe(double oe, double t) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
Reference in New Issue
Block a user