System.Xml.Tests.TCFullEndElement.TCWriteChars.writeChars_4 C# (CSharp) Méthode

writeChars_4() public méthode

public writeChars_4 ( ) : int
Résultat int
            public int writeChars_4()
            {
                using (XmlWriter w = CreateWriter())
                {
                    string s = "this is an entity &foo;";
                    char[] buf = s.ToCharArray();

                    w.WriteStartElement("Root");
                    w.WriteChars(buf, 0, buf.Length);
                    w.WriteEndElement();
                }
                return CompareReader("<Root>this is an entity &amp;foo;</Root>") ? TEST_PASS : TEST_FAIL;
            }