Csharp/C Sharp by API/System.Xml.Linq/SaveOptions — различия между версиями
Admin (обсуждение | вклад) м (1 версия) |
Admin (обсуждение | вклад) м (1 версия) |
(нет различий)
|
Текущая версия на 15:11, 26 мая 2010
SaveOptions.DisableFormatting
<source lang="csharp"> using System; using System.Collections.Generic; using System.Linq; using System.Xml.Linq; public class MainClass {
public static void Main() { var bench = new XElement("bench", new XElement("t", new XElement("B", "H"), new XElement("A", "R") ), new XElement("t", new XElement("B", "S"), new XElement("A", "N") ), new XComment("This is the comment") ); foreach (XNode node in bench.Nodes()) Console.WriteLine(node.ToString(SaveOptions.DisableFormatting) + "."); }
}
</source>