mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-10 18:24:50 +00:00
docs: complete XML documentation for all projects with inheritdoc tags
Co-authored-by: andrew-welker <1765622+andrew-welker@users.noreply.github.com>
This commit is contained in:
@@ -91,10 +91,22 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
public event PresetRecalledCallback PresetRecalled;
|
||||
public event PresetsSavedCallback PresetsSaved;
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the PulseTime
|
||||
/// </summary>
|
||||
public int PulseTime { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the DigitSpacingMs
|
||||
/// </summary>
|
||||
public int DigitSpacingMs { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the PresetsAreLoaded
|
||||
/// </summary>
|
||||
public bool PresetsAreLoaded { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the PresetsList
|
||||
/// </summary>
|
||||
public List<PresetChannel> PresetsList { get; private set; }
|
||||
|
||||
public int Count
|
||||
@@ -102,13 +114,28 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
get { return PresetsList != null ? PresetsList.Count : 0; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the UseLocalImageStorage
|
||||
/// </summary>
|
||||
public bool UseLocalImageStorage { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the ImagesLocalHostPrefix
|
||||
/// </summary>
|
||||
public string ImagesLocalHostPrefix { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the ImagesPathPrefix
|
||||
/// </summary>
|
||||
public string ImagesPathPrefix { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the ListPathPrefix
|
||||
/// </summary>
|
||||
public string ListPathPrefix { get; set; }
|
||||
public event EventHandler PresetsLoaded;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// SetFileName method
|
||||
/// </summary>
|
||||
public void SetFileName(string path)
|
||||
{
|
||||
_filePath = ListPathPrefix + path;
|
||||
@@ -117,6 +144,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
LoadChannels();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// LoadChannels method
|
||||
/// </summary>
|
||||
public void LoadChannels()
|
||||
{
|
||||
try
|
||||
@@ -155,6 +185,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Dial method
|
||||
/// </summary>
|
||||
public void Dial(int presetNum)
|
||||
{
|
||||
if (presetNum <= PresetsList.Count)
|
||||
@@ -163,6 +196,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Dial method
|
||||
/// </summary>
|
||||
public void Dial(string chanNum)
|
||||
{
|
||||
if (_dialIsRunning || !_initSuccess)
|
||||
@@ -199,6 +235,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
OnPresetRecalled(_setTopBox, chanNum);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Dial method
|
||||
/// </summary>
|
||||
public void Dial(int presetNum, ISetTopBoxNumericKeypad setTopBox)
|
||||
{
|
||||
if (presetNum <= PresetsList.Count)
|
||||
@@ -207,6 +246,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Dial method
|
||||
/// </summary>
|
||||
public void Dial(string chanNum, ISetTopBoxNumericKeypad setTopBox)
|
||||
{
|
||||
_dialFunctions = new Dictionary<char, Action<bool>>(10)
|
||||
@@ -243,6 +285,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
handler(setTopBox, channel);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// UpdatePreset method
|
||||
/// </summary>
|
||||
public void UpdatePreset(int index, PresetChannel preset)
|
||||
{
|
||||
if (index >= PresetsList.Count)
|
||||
@@ -257,6 +302,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
OnPresetsSaved();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// UpdatePresets method
|
||||
/// </summary>
|
||||
public void UpdatePresets(List<PresetChannel> presets)
|
||||
{
|
||||
PresetsList = presets;
|
||||
|
||||
@@ -8,13 +8,31 @@ using Crestron.SimplSharpPro.DeviceSupport;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Presets
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a DevicePresetsView
|
||||
/// </summary>
|
||||
public class DevicePresetsView
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets or sets the ShowNumbers
|
||||
/// </summary>
|
||||
public bool ShowNumbers { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the ShowName
|
||||
/// </summary>
|
||||
public bool ShowName { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the ShowIcon
|
||||
/// </summary>
|
||||
public bool ShowIcon { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the SRL
|
||||
/// </summary>
|
||||
public SubpageReferenceList SRL { get; private set; }
|
||||
/// <summary>
|
||||
/// Gets or sets the Model
|
||||
/// </summary>
|
||||
public DevicePresetsModel Model { get; private set; }
|
||||
|
||||
public DevicePresetsView(BasicTriListWithSmartObject tl, DevicePresetsModel model)
|
||||
@@ -32,6 +50,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
Model.PresetsLoaded += new EventHandler(Model_PresetsLoaded);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Attach method
|
||||
/// </summary>
|
||||
public void Attach()
|
||||
{
|
||||
if (Model.PresetsAreLoaded)
|
||||
@@ -46,6 +67,9 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Detach method
|
||||
/// </summary>
|
||||
public void Detach()
|
||||
{
|
||||
SRL.Clear();
|
||||
|
||||
@@ -10,24 +10,39 @@ using Newtonsoft.Json;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Presets
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a PresetBase
|
||||
/// </summary>
|
||||
public class PresetBase
|
||||
{
|
||||
[JsonProperty("id")]
|
||||
/// <summary>
|
||||
/// Gets or sets the ID
|
||||
/// </summary>
|
||||
public int ID { get; set; }
|
||||
/// <summary>
|
||||
/// Used to store the name of the preset
|
||||
/// </summary>
|
||||
[JsonProperty("description")]
|
||||
/// <summary>
|
||||
/// Gets or sets the Description
|
||||
/// </summary>
|
||||
public string Description { get; set; }
|
||||
/// <summary>
|
||||
/// Indicates if the preset is defined(stored) in the codec
|
||||
/// </summary>
|
||||
[JsonProperty("defined")]
|
||||
/// <summary>
|
||||
/// Gets or sets the Defined
|
||||
/// </summary>
|
||||
public bool Defined { get; set; }
|
||||
/// <summary>
|
||||
/// Indicates if the preset has the capability to be defined
|
||||
/// </summary>
|
||||
[JsonProperty("isDefinable")]
|
||||
/// <summary>
|
||||
/// Gets or sets the IsDefinable
|
||||
/// </summary>
|
||||
public bool IsDefinable { get; set; }
|
||||
|
||||
public PresetBase(int id, string description, bool def, bool isDef)
|
||||
|
||||
@@ -9,25 +9,46 @@ using Newtonsoft.Json;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Presets
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a PresetChannel
|
||||
/// </summary>
|
||||
public class PresetChannel
|
||||
{
|
||||
|
||||
[JsonProperty(Required = Required.Always,PropertyName = "name")]
|
||||
/// <summary>
|
||||
/// Gets or sets the Name
|
||||
/// </summary>
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonProperty(Required = Required.Always, PropertyName = "iconUrl")]
|
||||
/// <summary>
|
||||
/// Gets or sets the IconUrl
|
||||
/// </summary>
|
||||
public string IconUrl { get; set; }
|
||||
|
||||
[JsonProperty(Required = Required.Always, PropertyName = "channel")]
|
||||
/// <summary>
|
||||
/// Gets or sets the Channel
|
||||
/// </summary>
|
||||
public string Channel { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Represents a PresetsList
|
||||
/// </summary>
|
||||
public class PresetsList
|
||||
{
|
||||
[JsonProperty(Required=Required.Always,PropertyName = "name")]
|
||||
/// <summary>
|
||||
/// Gets or sets the Name
|
||||
/// </summary>
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonProperty(Required = Required.Always, PropertyName = "channels")]
|
||||
/// <summary>
|
||||
/// Gets or sets the Channels
|
||||
/// </summary>
|
||||
public List<PresetChannel> Channels { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -12,6 +12,9 @@ using Serilog.Events;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Presets
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a PresetsListSubpageReferenceListItem
|
||||
/// </summary>
|
||||
public class PresetsListSubpageReferenceListItem : SubpageReferenceListItem
|
||||
{
|
||||
DevicePresetsView View;
|
||||
@@ -27,6 +30,10 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
Refresh();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Clear method
|
||||
/// </summary>
|
||||
/// <inheritdoc />
|
||||
public override void Clear()
|
||||
{
|
||||
Owner.GetBoolFeedbackSig(Index, 1).UserObject = null;
|
||||
@@ -35,6 +42,10 @@ namespace PepperDash.Essentials.Core.Presets
|
||||
Owner.StringInputSig(Index, 3).StringValue = "";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Refresh method
|
||||
/// </summary>
|
||||
/// <inheritdoc />
|
||||
public override void Refresh()
|
||||
{
|
||||
var name = View.ShowName ? Channel.Name : "";
|
||||
|
||||
Reference in New Issue
Block a user