Last change
on this file since 17530 was
17519,
checked in by dpiringe, 5 years ago
|
#3026:
- added error output for failed runner initialization
- reorganised some final view models
- TargetedJsonItemType (in JsonItemVMBase) now automatically returns the type of the defined JsonItem
- code cleanup
- refactored RegressionProblemDataConverter
- added lots of comments
- added new view for StringArrayJsonItem
- added new UI component for concrete restricted items and used it in JsonItemConcreteItemArrayControl and JsonItemValidValuesControl
|
File size:
939 bytes
|
Line | |
---|
1 | using System;
|
---|
2 | using System.Collections.Generic;
|
---|
3 | using System.ComponentModel;
|
---|
4 | using System.Linq;
|
---|
5 | using System.Text;
|
---|
6 | using System.Threading.Tasks;
|
---|
7 | using System.Windows.Forms;
|
---|
8 |
|
---|
9 | namespace HeuristicLab.JsonInterface.OptimizerIntegration {
|
---|
10 |
|
---|
11 | public class BoolValueVM : JsonItemVMBase<BoolJsonItem> {
|
---|
12 |
|
---|
13 | public bool Value {
|
---|
14 | get => Item.Value;
|
---|
15 | set {
|
---|
16 | Item.Value = value;
|
---|
17 | OnPropertyChange(this, nameof(Value));
|
---|
18 | }
|
---|
19 | }
|
---|
20 |
|
---|
21 | public override UserControl Control =>
|
---|
22 | new JsonItemBoolControl(this);
|
---|
23 | }
|
---|
24 |
|
---|
25 | public abstract class SingleValueVM<T, JsonItemType> : RangedValueBaseVM<T, JsonItemType>
|
---|
26 | where T : IComparable
|
---|
27 | where JsonItemType : class, IIntervalRestrictedJsonItem<T>, IValueJsonItem<T>
|
---|
28 | {
|
---|
29 |
|
---|
30 | public T Value {
|
---|
31 | get => Item.Value;
|
---|
32 | set {
|
---|
33 | Item.Value = value;
|
---|
34 | OnPropertyChange(this, nameof(Value));
|
---|
35 | }
|
---|
36 | }
|
---|
37 | }
|
---|
38 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.