diff options
| author | Jean-Philippe Bruyère <jp_bruyere@hotmail.com> | 2018-02-24 11:51:12 +0100 |
|---|---|---|
| committer | Jean-Philippe Bruyère <jp_bruyere@hotmail.com> | 2018-02-24 11:51:12 +0100 |
| commit | af3a87ef16e2f4df9fa01a89fd709125c91188d6 (patch) | |
| tree | 506b54417e5e9f2ccb8e17b90642ad94060ccc91 /CrowIDE/src/SourceEditor/Node.cs | |
| parent | 1293bc896bdbc6819999d17bda8286a6e1a792b0 (diff) | |
change namespace of CrowIDE to Crow.Coding, move editor source inside, crowIde wip
Diffstat (limited to 'CrowIDE/src/SourceEditor/Node.cs')
| -rw-r--r-- | CrowIDE/src/SourceEditor/Node.cs | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/CrowIDE/src/SourceEditor/Node.cs b/CrowIDE/src/SourceEditor/Node.cs new file mode 100644 index 00000000..24818e01 --- /dev/null +++ b/CrowIDE/src/SourceEditor/Node.cs @@ -0,0 +1,32 @@ +using System; +using System.Collections.Generic; + +namespace Crow.Coding +{ + public class Node + { + public Node Parent; + public string Name; + public string Type; + public CodeLine StartLine; + public CodeLine EndLine; + public Dictionary<string,string> Attributes = new Dictionary<string, string> (); + + public List<Node> Children = new List<Node>(); + + public Node () + { + } + + public void AddChild (Node child) { + child.Parent = this; + Children.Add (child); + } + + public override string ToString () + { + return string.Format ("Name:{0}, Type:{1}\n\tparent:{2}", Name, Type, Parent); + } + } +} + |