title: Java JSoup: what does this message mean?
body: <p>I want to use the JSoup project to validate html fragments.  All I really want to know is whether the fragment is valid HTML or not.
  JSoup does return errors if a flag is set on the parser.  But when I run the parser on this fragment:</p>
  
  <pre><code>"This is a &lt;br/&gt; test"
  </code></pre>
  
  <p>I get this error message <strong>"Self closing flag not acknowledged"</strong>
  I don't know what this means or whether it is really intended to be an error, since the <code>ParseError</code> class has only two properties, a text and an error position.</p>
  
  <p>Also, it seems inconsistent.  This, for example is OK:</p>
  
  <pre><code>"This is a &lt;br&gt; test"
  </code></pre>
  
  <p>This is also OK:</p>
  
  <pre><code>"&lt;br/&gt; This is a test"
  </code></pre>
  
  <p>The key to generating this error message seems to be plain text appearing before the <br> tag with self-closing in the tag (<code>&lt;br/&gt;</code>).</p>
  
  <p>Does anyone know what, exactly, this message means and why it is an error and not a warning, and why this behavior?</p>
  
  <p>Thanks</p>