using System;
using System.Collections.Generic;
using Newtonsoft.Json;
using PepperDash.Core;
namespace PepperDash.Essentials.Core
{
///
/// Describes the functionality for an EssentailsRoomCombiner device
///
public interface IEssentialsRoomCombiner : IKeyed
{
///
/// Indicates that the room combination scenario has changed
///
event EventHandler RoomCombinationScenarioChanged;
///
/// The current room combination scenario
///
[JsonProperty("currentScenario")]
IRoomCombinationScenario CurrentScenario { get; }
///
/// When true, indicates the current mode is auto mode
///
[JsonIgnore]
BoolFeedback IsInAutoModeFeedback {get;}
[JsonProperty("isInAutoMode")]
bool IsInAutoMode { get; }
[JsonProperty("rooms")]
List Rooms { get; }
///
/// Sets auto mode
///
void SetAutoMode();
///
/// Sets manual mode
///
void SetManualMode();
///
/// Toggles the current mode between auto and manual
///
void ToggleMode();
///
/// The available room combinatino scenarios
///
[JsonProperty("roomCombinationScenarios")]
List RoomCombinationScenarios { get; }
///
/// The partition
///
[JsonProperty("partitions")]
List Partitions { get; }
///
/// Toggles the state of a manual partition sensor
///
///
void TogglePartitionState(string partitionKey);
///
/// Sets the room combination scenario (if in manual mode)
///
///
void SetRoomCombinationScenario(string scenarioKey);
}
public interface IRoomCombinationScenario : IKeyName
{
///
/// When true, indicates that this room combination scenario is active
///
[JsonIgnore]
BoolFeedback IsActiveFeedback { get; }
[JsonProperty("isActive")]
bool IsActive { get; }
///
/// Activates this room combination scenario
///
void Activate();
///
/// Deactivates this room combination scenario
///
void Deactivate();
///
/// The state of the partitions that would activate this scenario
///
[JsonProperty("partitionStates")]
List PartitionStates { get; }
///
/// The mapping of UIs by key to rooms by key
///
[JsonProperty("uiMap")]
Dictionary UiMap { get; set; }
}
}