mirror of
https://github.com/PepperDash/PepperDashCore.git
synced 2026-02-16 13:14: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>
|
||||||
///
|
///
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -10,6 +10,12 @@ namespace PepperDash.Core.DebugThings
|
|||||||
{
|
{
|
||||||
public class DebugContextCollection
|
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")]
|
[JsonProperty("items")]
|
||||||
Dictionary<string, DebugContextItem> Items;
|
Dictionary<string, DebugContextItem> Items;
|
||||||
|
|
||||||
@@ -47,6 +53,9 @@ namespace PepperDash.Core.DebugThings
|
|||||||
|
|
||||||
public class DebugContextItem
|
public class DebugContextItem
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The level of debug messages to print
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("level")]
|
[JsonProperty("level")]
|
||||||
public int Level { get; set; }
|
public int Level { get; set; }
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user