mirror of
https://github.com/PepperDash/PepperDashCore.git
synced 2026-02-03 06:44:49 +00:00
Adds a flag to the debug context class to save whether or not an application should start after the next boot.
This commit is contained in:
@@ -237,6 +237,18 @@ namespace PepperDash.Core
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sets the flag to prevent application starting on next boot
|
||||
/// </summary>
|
||||
/// <param name="state"></param>
|
||||
public static void SetDoNotStartOnNextBoot(bool state)
|
||||
{
|
||||
Contexts.DoNotStartOnNextBoot = state;
|
||||
CrestronConsole.PrintLine("[Application {0}], Do Not Start on Next Boot set to {1}",
|
||||
InitialParametersClass.ApplicationNumber, Contexts.DoNotStartOnNextBoot);
|
||||
SaveMemoryOnTimeout();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
|
||||
@@ -10,6 +10,12 @@ namespace PepperDash.Core.DebugThings
|
||||
{
|
||||
public class DebugContextCollection
|
||||
{
|
||||
/// <summary>
|
||||
/// Property to tell the program not to intitialize when it boots, if desired
|
||||
/// </summary>
|
||||
[JsonProperty("doNotStartOnNextBoot")]
|
||||
public bool DoNotStartOnNextBoot { get; set; }
|
||||
|
||||
[JsonProperty("items")]
|
||||
Dictionary<string, DebugContextItem> Items;
|
||||
|
||||
@@ -47,6 +53,9 @@ namespace PepperDash.Core.DebugThings
|
||||
|
||||
public class DebugContextItem
|
||||
{
|
||||
/// <summary>
|
||||
/// The level of debug messages to print
|
||||
/// </summary>
|
||||
[JsonProperty("level")]
|
||||
public int Level { get; set; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user