Free cookie consent management tool by TermsFeed Policy Generator

source: branches/2895_PushGP_GenealogyAnalysis/HeuristicLab.Problems.ProgramSynthesis/Push.Base/Erc/ErcOption.cs @ 17511

Last change on this file since 17511 was 15771, checked in by bburlacu, 7 years ago

#2895: Add solution skeleton for PushGP with genealogy analysis.

File size: 810 bytes
RevLine 
[15771]1namespace HeuristicLab.Problems.ProgramSynthesis {
[14897]2  using HeuristicLab.Common;
[14905]3  using HeuristicLab.Core;
[14897]4  using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
[14875]5
6  [StorableClass]
[14897]7  public abstract class ErcOption<T> : ErcOptionConvertible<T, T> {
[14952]8    protected ErcOption() : this(false, new WeightedErcItem<T>[0]) { }
[14875]9
[14952]10    protected ErcOption(bool isEnabled, params WeightedErcItem<T>[] values)
[14905]11        : base(isEnabled, values) { }
[14875]12
13    [StorableConstructor]
[14897]14    protected ErcOption(bool deserializing)
15        : base(deserializing) {
[14875]16    }
17
[14897]18    protected ErcOption(ErcOptionConvertible<T, T> origin, Cloner cloner)
19        : base(origin, cloner) {
[14875]20    }
[14905]21
22    public override T GetErcValue(IRandom random) {
23      return GetErcValue(random, x => x);
24    }
[14875]25  }
26}
Note: See TracBrowser for help on using the repository browser.