mirror of
https://github.com/PepperDash/PepperDashCore.git
synced 2026-04-12 12:06:29 +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:
parent
3f00f92e49
commit
acf9514fc5
2 changed files with 21 additions and 0 deletions
|
|
@ -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; }
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue