feature: updated folder structure

- moved files into folders to match their current namespace
- did not update any namespaces to maintain backward compatibility
This commit is contained in:
Nick Genovese
2023-10-26 10:22:25 -04:00
parent 14b6900460
commit f640f0f911
615 changed files with 12499 additions and 11136 deletions

View File

@@ -1,7 +1,6 @@
extern alias Full;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
@@ -10,8 +9,6 @@ using PepperDash.Core;
using PepperDash.Essentials.Core;
using PepperDash.Essentials.Core.Config;
using Full.Newtonsoft.Json;
namespace PepperDash.Essentials.Core.Timers
{
@@ -127,53 +124,4 @@ namespace PepperDash.Essentials.Core.Timers
//}
}
}
/// <summary>
/// Configuration Properties for RetriggerableTimer
/// </summary>
public class RetriggerableTimerPropertiesConfig
{
[JsonProperty("startTimerOnActivation")]
public bool StartTimerOnActivation { get; set; }
[JsonProperty("timerIntervalMs")]
public long TimerIntervalMs { get; set; }
[JsonProperty("events")]
public Dictionary<eRetriggerableTimerEvents, DeviceActionWrapper> Events { get; set; }
public RetriggerableTimerPropertiesConfig()
{
Events = new Dictionary<eRetriggerableTimerEvents, DeviceActionWrapper>();
}
}
/// <summary>
/// The set of values describing events on the timer
/// </summary>
public enum eRetriggerableTimerEvents
{
Elapsed,
Stopped,
}
/// <summary>
/// Factory class
/// </summary>
public class RetriggerableTimerFactory : EssentialsDeviceFactory<RetriggerableTimer>
{
public RetriggerableTimerFactory()
{
TypeNames = new List<string>() { "retriggerabletimer" };
}
public override EssentialsDevice BuildDevice(DeviceConfig dc)
{
Debug.Console(1, "Factory Attempting to create new RetriggerableTimer Device");
return new RetriggerableTimer(dc.Key, dc);
}
}
}

View File

@@ -0,0 +1,24 @@
using System.Collections.Generic;
using PepperDash.Core;
using PepperDash.Essentials.Core.Config;
namespace PepperDash.Essentials.Core.Timers
{
/// <summary>
/// Factory class
/// </summary>
public class RetriggerableTimerFactory : EssentialsDeviceFactory<RetriggerableTimer>
{
public RetriggerableTimerFactory()
{
TypeNames = new List<string>() { "retriggerabletimer" };
}
public override EssentialsDevice BuildDevice(DeviceConfig dc)
{
Debug.Console(1, "Factory Attempting to create new RetriggerableTimer Device");
return new RetriggerableTimer(dc.Key, dc);
}
}
}

View File

@@ -0,0 +1,26 @@
extern alias Full;
using System.Collections.Generic;
using Full::Newtonsoft.Json;
namespace PepperDash.Essentials.Core.Timers
{
/// <summary>
/// Configuration Properties for RetriggerableTimer
/// </summary>
public class RetriggerableTimerPropertiesConfig
{
[JsonProperty("startTimerOnActivation")]
public bool StartTimerOnActivation { get; set; }
[JsonProperty("timerIntervalMs")]
public long TimerIntervalMs { get; set; }
[JsonProperty("events")]
public Dictionary<eRetriggerableTimerEvents, DeviceActionWrapper> Events { get; set; }
public RetriggerableTimerPropertiesConfig()
{
Events = new Dictionary<eRetriggerableTimerEvents, DeviceActionWrapper>();
}
}
}

View File

@@ -0,0 +1,11 @@
namespace PepperDash.Essentials.Core.Timers
{
/// <summary>
/// The set of values describing events on the timer
/// </summary>
public enum eRetriggerableTimerEvents
{
Elapsed,
Stopped,
}
}