public EstimateMoveNode AddChild(StoneMove move) { var child = new EstimateMoveNode(this, move); lock (_lock) { this._Children.Add(child); } return(child); }
private EstimateMoveNode(EstimateMoveNode parent, StoneMove move) { if (null == parent) { throw new ArgumentNullException("parent is null."); } if (null == move) { throw new ArgumentNullException("move is null."); } this.Parent = parent; this.Depth = Parent.Depth + 1; this.Move = move; this._Children = new List <EstimateMoveNode>(); InitializeState(); }