using System.Collections.Generic; using Newtonsoft.Json; using PepperDash.Essentials.Core.Config; namespace PepperDash.Essentials { /// /// Represents a MobileControlEssentialsConfig /// public class MobileControlEssentialsConfig : EssentialsConfig { [JsonProperty("runtimeInfo")] public MobileControlRuntimeInfo RuntimeInfo { get; set; } public MobileControlEssentialsConfig(EssentialsConfig config) : base() { // TODO: Consider using Reflection to iterate properties this.Devices = config.Devices; this.Info = config.Info; this.JoinMaps = config.JoinMaps; this.Rooms = config.Rooms; this.SourceLists = config.SourceLists; this.DestinationLists = config.DestinationLists; this.SystemUrl = config.SystemUrl; this.TemplateUrl = config.TemplateUrl; this.TieLines = config.TieLines; if (this.Info == null) this.Info = new InfoConfig(); RuntimeInfo = new MobileControlRuntimeInfo(); } } /// /// Represents a MobileControlRuntimeInfo /// public class MobileControlRuntimeInfo { /// /// Gets or sets the PluginVersion /// [JsonProperty("pluginVersion")] public string PluginVersion { get; set; } [JsonProperty("essentialsVersion")] public string EssentialsVersion { get; set; } [JsonProperty("pepperDashCoreVersion")] public string PepperDashCoreVersion { get; set; } /// /// Gets or sets the EssentialsPlugins /// [JsonProperty("essentialsPlugins")] public List EssentialsPlugins { get; set; } } }