title: XSD requiring a specific root element exist in an XML document?
body: <p>I want to validate a XML file and to make sure it has a root element called <code>speak</code> like this:</p>
  
  <pre><code>&lt;speak&gt;
    &lt;!--other node here...--&gt;
  &lt;/speak&gt;
  </code></pre>
  
  <p>the <code>speak</code> element must exist in XML and must appears only once. I try to add code below in my XSD file:</p>
  
  <pre><code>&lt;xsd:element name="speak" type="speak" minOccurs="1" maxOccurs="1"/&gt;
  </code></pre>
  
  <p>But it does not work.</p>