using HeuristicLab.Common; using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding; using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; namespace HeuristicLab.Problems.Robocode { [StorableClass] public class Constant : Symbol { public override int MinimumArity { get { return 0; } } public override int MaximumArity { get { return 0; } } [StorableConstructor] private Constant(bool deserializing) : base(deserializing) { } private Constant(Constant original, Cloner cloner) : base(original, cloner) { } public Constant() : base("Constant", "A random fixed integer.") { } public override ISymbolicExpressionTreeNode CreateTreeNode() { return new ConstantTreeNode(); } public override IDeepCloneable Clone(Cloner cloner) { return new Constant(this, cloner); } } }