diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/IPartitionStateProvider.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/IPartitionStateProvider.cs index 0080e472..08b8012b 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/IPartitionStateProvider.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/IPartitionStateProvider.cs @@ -4,13 +4,24 @@ using System.Linq; using System.Text; using Crestron.SimplSharp; +using PepperDash.Core; + namespace PepperDash.Essentials.Core { /// /// Describes the functionality of a device that senses and provides partition state /// - public interface IPartitionStateProvider + public interface IPartitionStateProvider : IKeyName { BoolFeedback PartitionSensedFeedback { get; } } + + public interface IManualPartitionSensor : IPartitionStateProvider + { + void SetPartitionStatePresent(); + + void SetPartitionStateNotPresent(); + + void ToggglePartitionState(); + } } \ No newline at end of file diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj index 7e18606f..b65cfd62 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj @@ -289,6 +289,8 @@ + + diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/EssentialsRoomCombinerPropertiesConfig.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/EssentialsRoomCombinerPropertiesConfig.cs index 5f1adcfa..74d5ebda 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/EssentialsRoomCombinerPropertiesConfig.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/EssentialsRoomCombinerPropertiesConfig.cs @@ -8,21 +8,30 @@ using PepperDash.Core; using Newtonsoft.Json; -namespace PepperDash.Essentials.Core.Room +namespace PepperDash.Essentials.Core { /// /// Config properties for an EssentialsRoomCombiner device /// public class EssentialsRoomCombinerPropertiesConfig { + /// + /// The list of partitions that device the rooms + /// [JsonProperty("partitions")] public List Partitions {get; set;} + /// + /// The list of combinations scenarios for the rooms + /// [JsonProperty("scenarios")] - public List Scenarios { get; set; } + public List Scenarios { get; set; } - [JsonProperty("rooms")] - public List Rooms {get; set;} + /// + /// The list of rooms that can be combined + /// + [JsonProperty("roomMap")] + public Dictionary RoomMap {get; set;} } /// @@ -46,7 +55,7 @@ namespace PepperDash.Essentials.Core.Room /// /// Config propeties for a room combination scenario /// - public class RoomCombinationScenario : IKeyName + public class RoomCombinationScenarioConfig : IKeyName { [JsonProperty("partitionStates")] public List PartitionStates { get; set; } @@ -67,6 +76,6 @@ namespace PepperDash.Essentials.Core.Room public string PartitionKey { get; set; } [JsonProperty("partitionSensedState")] - public bool PartitionSensedState { get; set; } + public bool PartitionPresent { get; set; } } } \ No newline at end of file diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/IEssentialsRoomCombiner.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/IEssentialsRoomCombiner.cs new file mode 100644 index 00000000..894dd098 --- /dev/null +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/IEssentialsRoomCombiner.cs @@ -0,0 +1,41 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Crestron.SimplSharp; + +using PepperDash.Core; + +namespace PepperDash.Essentials.Core +{ + /// + /// Describes the functionality for an EssentailsRoomCombiner device + /// + public interface IEssentialsRoomCombiner + { + // TODO: Update the EventArgs class as needed to specify scenario change + event EventHandler RoomCombinationScenarioChanged; + + BoolFeedback IsInAutoModeFeedback {get;} + + void SetAutoMode(); + + void SetManualMode(); + + void ToggleMode(); + + List Scenarios { get; } + + List Partitions { get; } + + void TogglePartitionState(string partitionKey); + } + + public interface IRoomCombinationScenario : IKeyName + { + BoolFeedback IsActive { get; } + + void Activate(); + } + +} \ No newline at end of file diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/RoomCombinationScenario.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/RoomCombinationScenario.cs new file mode 100644 index 00000000..965428cb --- /dev/null +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Room/Combining/RoomCombinationScenario.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Crestron.SimplSharp; + +namespace PepperDash.Essentials.Core +{ + /// + /// Represents a room combination scenario + /// + public class RoomCombinationScenario: IRoomCombinationScenario + { + + } + +} \ No newline at end of file