Last change
on this file was
17843,
checked in by dpiringe, 3 years ago
|
#3026
- removed property ConvertableType from all converters
- removed the option to fixate or loosen the path of JsonItems (obsolete)
- added a abstract formatter SymbolicRegressionSolutionFormatterBase as base formatter for ISymbolicRegressionSolution
- unified the construction of exporter controls
- code cleanup
|
File size:
624 bytes
|
Line | |
---|
1 | using System.Linq;
|
---|
2 |
|
---|
3 | namespace HeuristicLab.JsonInterface.OptimizerIntegration {
|
---|
4 | public class StringValueVM : ConcreteRestrictedJsonItemVM<StringJsonItem, string, string> {
|
---|
5 | protected override string GetDefaultValue() => Range.FirstOrDefault();
|
---|
6 | protected override bool RangeContainsValue() => Range.Contains(Item.Value);
|
---|
7 | }
|
---|
8 |
|
---|
9 | public class StringArrayVM : ConcreteRestrictedJsonItemVM<StringArrayJsonItem, string, string[]> {
|
---|
10 | protected override string[] GetDefaultValue() => Range.ToArray();
|
---|
11 | protected override bool RangeContainsValue() => Item.Value.All(x => Range.Any(y => x == y));
|
---|
12 | }
|
---|
13 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.