Example #1
0
 public void AddChild(PlanNodeDO child, int?ordering)
 {
     child.Ordering = ordering ?? (ChildNodes.Count > 0 ? ChildNodes.Max(x => x.Ordering) + 1 : 1);
     ChildNodes.Add(child);
 }
Example #2
0
 public void AddChildWithDefaultOrdering(PlanNodeDO child)
 {
     child.Ordering = ChildNodes.Count > 0 ? ChildNodes.Max(x => x.Ordering) + 1 : 1;
     ChildNodes.Add(child);
 }