示例#1
0
 public SettingsGroupsCollection(IEnumerable <Type> taskSettings)
 {
     foreach (var taskType in taskSettings)
     {
         var groups = SettingsIni.GetSections(taskType.Name);
         groups.ForEach(x => _list.Add(SettingsIni.GetGroupName(x)));
     }
     _list = _list.Distinct().ToList();
 }
示例#2
0
 public SettingsRepresentCollection(Type settingRepresentType)
 {
     SettingsRepresentTypeName = settingRepresentType.Name;
     SettingsIni.GetSections(SettingsRepresentTypeName).ForEach(t => _list.Add(Activator.CreateInstance(settingRepresentType, t)));
 }