private void AddAction(ActionBase agg) { if (agg == null) return; var combinator = agg as ActionCombinator; if ((combinator?.Actions.HasAny()).GetValueOrDefault(false)) { this.Actions.AddRange(combinator.Actions); } else this.Actions.Add(agg); }
public ActionCombinator(ActionBase left, ActionBase right) : base(null) { this.AddAction(left); this.AddAction(right); }