Refactored how configuration, IR and SGD file path prefixes are handled, in order to be able to handle a different file structure if running on XiO Edge

This commit is contained in:
Neil Dorin
2018-03-27 16:39:23 -06:00
parent fb19b5894b
commit ce6cecbb79
12 changed files with 63 additions and 36 deletions

View File

@@ -20,7 +20,7 @@ namespace PepperDash.Essentials.Core
{
get
{
return string.Format(@"\NVRAM\Program{0}\IR\", InitialParametersClass.ApplicationNumber);
return Global.FilePathPrefix + @"IR\";
}
}

View File

@@ -13,19 +13,18 @@ namespace PepperDash.Essentials.Core
{
public static CrestronControlSystem ControlSystem { get; set; }
public static LicenseManager LicenseManager { get; set; }
//public static EssentialsHttpServer HttpConfigServer
//{
// get
// {
// if (_HttpConfigServer == null)
// _HttpConfigServer = new EssentialsHttpServer();
// return _HttpConfigServer;
// }
//}
//static EssentialsHttpServer _HttpConfigServer;
public static LicenseManager LicenseManager { get; set; }
public static string FilePathPrefix { get; private set; }
/// <summary>
/// Sets the file path prefix
/// </summary>
/// <param name="prefix"></param>
public static void SetFilePathPrefix(string prefix)
{
FilePathPrefix = prefix;
}
static Global()
{