public static void ListPlaces()
{
string siteDir = HttpContext.Current.Server.MapPath(@"\");
XmlTextReader reader = new XmlTextReader(siteDir + InputFile);
Hall pList = new Hall();
Places p = null;
int category = 0;
int series = 0;
int place = 0;
while (reader.Read())
{
if (reader.NodeType == XmlNodeType.Element)
{
switch (reader.Name)
{
case "category":
reader.MoveToNextAttribute();
category = Int32.Parse(reader.Value);
break;
case "row":
reader.MoveToNextAttribute();
series = Int32.Parse(reader.Value);
break;
case "seat":
reader.Read();
place = Int32.Parse(reader.Value);
p = new Places(series, place, category);
pList.Add(p);
break;
}
}
}
}