示例#1
0
文件: Node.cs 项目: danthomas/Parsing
 private Node(Node parent, TokenType tokenType, string text = "")
 {
     Parent = parent;
     TokenType = tokenType;
     Text = text ?? "";
     Children = new List<Node>();
 }
示例#2
0
文件: Node.cs 项目: danthomas/Parsing
 public Node AddChild(TokenType tokenType, string text = "")
 {
     Node child = new Node(this, tokenType, text);
     Children.Add(child);
     return child;
 }