-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathNestedElementFile.cs
More file actions
28 lines (26 loc) · 876 Bytes
/
NestedElementFile.cs
File metadata and controls
28 lines (26 loc) · 876 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
namespace VDF {
public class NestedElementFile {
public Dictionary<String, NestedElement> Elements = new Dictionary<string, NestedElement>();
public NestedElementFile(String file_name) {
TextReader read = new StreamReader(file_name);
Queue<string> lines = new Queue<string>();
String line = read.ReadLine();
while (line != null) {
lines.Enqueue(line);
line = read.ReadLine();
}
while(lines.Count>0) {
NestedElement ele = new NestedElement(lines);
if (ele.Ready) {
Elements.Add(ele.Name,ele);
}
}
System.Console.Out.WriteLine("adas");
}
}
}