Example #1
0
 private static void AddItemIfNotEmpty(CapabilityTag capabilityTag, List <CapabilityTag> capabilities)
 {
     if (!string.IsNullOrEmpty(capabilityTag.Name))
     {
         capabilities.Add(capabilityTag);
     }
 }
        public DisplayCapabilities(List <CapabilityTag> capabilityTags)
        {
            this.CapabilityTags = capabilityTags;

            this.Protocol = this.GetValue("prot");
            this.Type     = this.GetValue("type");
            this.Model    = this.GetValue("model");

            var versionStr = this.GetValue("mccs_ver");

            if (!string.IsNullOrEmpty(versionStr) && Version.TryParse(versionStr, out var parsedMccsVersion))
            {
                this.MccsVersion = parsedMccsVersion;
            }

            this.VirtualControlPanel = this.GetTag("vcp");
        }