Corpus-Cypher-Executable/cce/App.cs
2022-04-18 16:53:21 +02:00

40 lines
1.2 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Newtonsoft.Json;
using System.IO;
using System.Windows.Forms;
using static System.Console;
using static System.Threading.Thread;
namespace cce {
internal class App {
static internal void Settings() {
// Finish Settings screen, make it interactable
}
}
internal class Path {
static internal string Common = "common.json";
static internal string Extended = "extended.json";
static internal string Settings = "settings.json";
}
internal class AppSettings {
static internal byte Check() {
if (!File.Exists(Path.Settings)) { File.WriteAllText(Path.Settings, JsonConvert.SerializeObject(AppSettings.ToDict())); return 1; }
else { return 0; }
}
static internal Dictionary<string, byte> ToDict () {
//Add properties and finish this method
return new Dictionary<string, byte> ();
}
static internal void Update() {
var settings = JsonConvert.DeserializeObject<Dictionary<string, byte>>(File.ReadAllText(Path.Settings));
}
}
}