/// <summary>
        /// Gets the property values detected by the detector.
        /// </summary>
        /// <returns>Name - value / values map.</returns>
        public Dictionary <string, List <string> > GetDetectedProperty()
        {
            Dictionary <string, List <string> > dict;

            detector.GetDetectedProperty(out dict);
            return(dict);
        }
        public void ApplyDetectedValues(ref IEnumerable <PropertyGroup> properties)
        {
            Dictionary <string, List <string> > propertiesByDetector;

            ValueDetector.GetDetectedProperty(out propertiesByDetector);
            List <PropertyGroup> updatedPropertyGroupList = new List <PropertyGroup>();

            foreach (var ptfconfigProperty in properties)
            {
                PropertyGroup newPropertyGroup = new PropertyGroup()
                {
                    Name  = ptfconfigProperty.Name,
                    Items = ptfconfigProperty.Items,
                };

                foreach (var item in ptfconfigProperty.Items)
                {
                    var propertyFromDetctor = propertiesByDetector.Where(i => i.Key == item.Key);
                    if (propertyFromDetctor.Count() > 0)
                    {
                        var detectorPropertyValue = propertyFromDetctor.FirstOrDefault().Value;
                        var newProperty           = newPropertyGroup.Items.Where(i => i.Key == item.Key).FirstOrDefault();
                        if (detectorPropertyValue.Count() == 1)
                        {
                            newProperty.Value = detectorPropertyValue[0];
                        }
                        else if (detectorPropertyValue.Count() > 0)
                        {
                            newProperty.Choices = detectorPropertyValue;
                            newProperty.Value   = detectorPropertyValue[0];
                        }
                    }
                }

                updatedPropertyGroupList.Add(newPropertyGroup);
            }
            properties = updatedPropertyGroupList.ToArray();
        }