/// <summary> /// Visit_inorders the specified visitor. Defined for debugging purposes only /// </summary> /// <param name="visitor">The visitor.</param> private void Visit(VisitNodeHandler <IntervalNode> visitor) { if (Root != null) { Root.Visit(visitor, 0); } }
public void Visit(VisitNodeHandler <IntervalNode> visitor, int level) { if (this.Left != null) { this.Left.Visit(visitor, level + 1); } visitor(this, level); if (this.Right != null) { this.Right.Visit(visitor, level + 1); } }