System.Xml.Xsl.Runtime.XmlQueryOutput.WriteStartRoot C# (CSharp) Method

WriteStartRoot() public method

Before calling XmlSequenceWriter.StartTree(), perform checks to ensure well-formedness.
public WriteStartRoot ( ) : void
return void
        public void WriteStartRoot() {
            Debug.Assert(this.depth == 0, "Root node can only be constructed at top-level.");
            if (this.xstate != XmlState.WithinSequence)
                ThrowInvalidStateError(XPathNodeType.Root);

            StartTree(XPathNodeType.Root);
            this.depth++;
        }