1 | namespace HeuristicLab.BenchmarkSuite {
|
---|
2 |
|
---|
3 | using HeuristicLab.Common;
|
---|
4 | using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
|
---|
5 |
|
---|
6 | [StorableClass]
|
---|
7 | public class Example : DeepCloneable {
|
---|
8 | private static readonly long[] emptyIntegers = new long[0];
|
---|
9 | private static readonly double[] emptyFloats = new double[0];
|
---|
10 | private static readonly bool[] emptyBooleans = new bool[0];
|
---|
11 | private static readonly char[] emptyChars = new char[0];
|
---|
12 | private static readonly string[] emptyStrings = new string[0];
|
---|
13 |
|
---|
14 |
|
---|
15 | public Example() {
|
---|
16 | InputInt = emptyIntegers;
|
---|
17 | InputFloat = emptyFloats;
|
---|
18 | InputBoolean = emptyBooleans;
|
---|
19 | InputChar = emptyChars;
|
---|
20 | InputString = emptyStrings;
|
---|
21 |
|
---|
22 | OutputInt = emptyIntegers;
|
---|
23 | OutputFloat = emptyFloats;
|
---|
24 | OutputBoolean = emptyBooleans;
|
---|
25 | OutputChar = emptyChars;
|
---|
26 | OutputString = emptyStrings;
|
---|
27 | }
|
---|
28 |
|
---|
29 | public Example(Example origin, Cloner cloner) : base(origin, cloner) {
|
---|
30 | InputArgs = (string[])origin.InputArgs.Clone();
|
---|
31 | OutputArgs = (string[])origin.OutputArgs.Clone();
|
---|
32 |
|
---|
33 | InputBoolean = (bool[])origin.InputBoolean.Clone();
|
---|
34 | InputInt = (long[])origin.InputInt.Clone();
|
---|
35 | InputFloat = (double[])origin.InputFloat.Clone();
|
---|
36 | InputChar = (char[])origin.InputChar.Clone();
|
---|
37 | InputString = (string[])origin.InputString.Clone();
|
---|
38 |
|
---|
39 | OutputBoolean = (bool[])origin.OutputBoolean.Clone();
|
---|
40 | OutputInt = (long[])origin.OutputInt.Clone();
|
---|
41 | OutputFloat = (double[])origin.OutputFloat.Clone();
|
---|
42 | OutputChar = (char[])origin.OutputChar.Clone();
|
---|
43 | OutputString = (string[])origin.OutputString.Clone();
|
---|
44 | }
|
---|
45 |
|
---|
46 | [StorableConstructor]
|
---|
47 | public Example(bool deserializing) { }
|
---|
48 |
|
---|
49 | [Storable]
|
---|
50 | public string[] InputArgs { get; set; }
|
---|
51 | [Storable]
|
---|
52 | public string[] OutputArgs { get; set; }
|
---|
53 |
|
---|
54 | [Storable]
|
---|
55 | public long[] InputInt { get; set; }
|
---|
56 | [Storable]
|
---|
57 | public double[] InputFloat { get; set; }
|
---|
58 | [Storable]
|
---|
59 | public bool[] InputBoolean { get; set; }
|
---|
60 | [Storable]
|
---|
61 | public char[] InputChar { get; set; }
|
---|
62 | [Storable]
|
---|
63 | public string[] InputString { get; set; }
|
---|
64 |
|
---|
65 | [Storable]
|
---|
66 | public long[] OutputInt { get; set; }
|
---|
67 | [Storable]
|
---|
68 | public double[] OutputFloat { get; set; }
|
---|
69 | [Storable]
|
---|
70 | public bool[] OutputBoolean { get; set; }
|
---|
71 | [Storable]
|
---|
72 | public char[] OutputChar { get; set; }
|
---|
73 | [Storable]
|
---|
74 | public string[] OutputString { get; set; }
|
---|
75 |
|
---|
76 | public override IDeepCloneable Clone(Cloner cloner) {
|
---|
77 | return new Example(this, cloner);
|
---|
78 | }
|
---|
79 | }
|
---|
80 | }
|
---|