Last change
on this file since 17712 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:
1.2 KB
|
Line | |
---|
1 | using System;
|
---|
2 | using System.Collections.Generic;
|
---|
3 | using System.Linq;
|
---|
4 | using System.Text;
|
---|
5 | using System.Threading.Tasks;
|
---|
6 | using System.Windows.Forms;
|
---|
7 |
|
---|
8 | namespace HeuristicLab.JsonInterface.OptimizerIntegration {
|
---|
9 | public class IntArrayValueVM : ArrayValueVM<int, IntArrayJsonItem> {
|
---|
10 |
|
---|
11 | protected override int MinTypeValue => int.MinValue;
|
---|
12 |
|
---|
13 | protected override int MaxTypeValue => int.MaxValue;
|
---|
14 |
|
---|
15 | public override UserControl Control =>
|
---|
16 | new JsonItemBaseControl(this, new JsonItemIntArrayValueControl(this));
|
---|
17 |
|
---|
18 | public override int[] Value {
|
---|
19 | get => Item.Value;
|
---|
20 | set {
|
---|
21 | Item.Value = value;
|
---|
22 | OnPropertyChange(this, nameof(Value));
|
---|
23 | }
|
---|
24 | }
|
---|
25 | }
|
---|
26 |
|
---|
27 | public class IntRangeVM : RangeVM<int, IntRangeJsonItem> {
|
---|
28 |
|
---|
29 | protected override int MinTypeValue => int.MinValue;
|
---|
30 |
|
---|
31 | protected override int MaxTypeValue => int.MaxValue;
|
---|
32 |
|
---|
33 | public override UserControl Control =>
|
---|
34 | new JsonItemRangeControl(this);
|
---|
35 | }
|
---|
36 |
|
---|
37 | public class IntValueVM : SingleValueVM<int, IntJsonItem> {
|
---|
38 |
|
---|
39 | protected override int MinTypeValue => int.MinValue;
|
---|
40 | protected override int MaxTypeValue => int.MaxValue;
|
---|
41 |
|
---|
42 | public override UserControl Control =>
|
---|
43 | new JsonItemIntValueControl(this);
|
---|
44 | }
|
---|
45 |
|
---|
46 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.