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
|
Rev | Line | |
---|
[17410] | 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 {
|
---|
[17411] | 10 |
|
---|
[17473] | 11 | public class BoolValueVM : JsonItemVMBase<BoolJsonItem> {
|
---|
[17411] | 12 |
|
---|
[17473] | 13 | public bool Value {
|
---|
| 14 | get => Item.Value;
|
---|
| 15 | set {
|
---|
| 16 | Item.Value = value;
|
---|
| 17 | OnPropertyChange(this, nameof(Value));
|
---|
| 18 | }
|
---|
| 19 | }
|
---|
| 20 |
|
---|
[17471] | 21 | public override UserControl Control =>
|
---|
| 22 | new JsonItemBoolControl(this);
|
---|
[17410] | 23 | }
|
---|
| 24 |
|
---|
[17473] | 25 | public abstract class SingleValueVM<T, JsonItemType> : RangedValueBaseVM<T, JsonItemType>
|
---|
| 26 | where T : IComparable
|
---|
| 27 | where JsonItemType : class, IIntervalRestrictedJsonItem<T>, IValueJsonItem<T>
|
---|
| 28 | {
|
---|
| 29 |
|
---|
[17410] | 30 | public T Value {
|
---|
[17473] | 31 | get => Item.Value;
|
---|
[17410] | 32 | set {
|
---|
[17412] | 33 | Item.Value = value;
|
---|
[17410] | 34 | OnPropertyChange(this, nameof(Value));
|
---|
| 35 | }
|
---|
| 36 | }
|
---|
| 37 | }
|
---|
| 38 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.