public Tree(Pile pile, Tree parent, Kind kind) { Parent = parent; Kind = kind; Children = new List <Tree>(0); Pile = pile; }
public Tree(string content, Kind kind, Tree parent = null) { Pile = new Pile(content); End = content.Length - 1; Kind = kind; Children = new List <Tree>(0); Parent = parent; }
public bool Set(bool save = true, bool Mark = true) { if (save) { Start = Pile.PilePos[Pile.PilePos.Count - 1]; End = Pile.CurrentPos - 1; Parent.Children.Add(this); } return(Pile.Leave(save, Mark)); }