public ComboBoxSettingViewModel( ISetting model, ISettingApplier settingsApplier, IEnumerable items, string description, object?itemTemplateViewOptions = null) : base(model, settingsApplier, description) { Items = items; ItemTemplateViewOptions = itemTemplateViewOptions; var org = OriginalValue; foreach (var item in items) { if (item == OriginalValue || item.Equals(OriginalValue)) { return; } } throw new ArgumentException("The start value must also be inside the provided items", nameof(items)); }
public TextSettingViewModel(ISetting model, ISettingApplier <string> settingsApplier, string description, IEnumerable <ValidationRule>?validationRules = null) : base(model, settingsApplier, description) { ValidationRules = validationRules?.ToList() ?? Enumerable.Empty <ValidationRule>(); }