using System; using System.Collections.Generic; using System.Linq; using System.Text; using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding; using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; using HeuristicLab.Common; using HeuristicLab.Core; namespace HeuristicLab.Problems.TradeRules.Symbols { public sealed class MACDTreeNode : SymbolicExpressionTreeNode { public new MACD Symbol { get { return (MACD)base.Symbol; } } [Storable] private double idMACD; public double ID { get {return idMACD; } set { idMACD = value; } } [StorableConstructor] private MACDTreeNode(bool deserializing) : base(deserializing) { } private MACDTreeNode(MACDTreeNode original, Cloner cloner) : base(original, cloner) { idMACD = original.idMACD; } public MACDTreeNode(MACD MACDSymbol) : base(MACDSymbol) { } public override bool HasLocalParameters { get { return true; } } public override void ResetLocalParameters(IRandom random) { base.ResetLocalParameters(random); idMACD = random.NextDouble(); } public override IDeepCloneable Clone(Cloner cloner) { return new MACDTreeNode(this, cloner); } } }