title: Why the jaxb documented property com.sun.xml.bind.xmlHeaders is not recognized but the "internal" one does?
body: <p>I'm confused about the <a href="https://javaee.github.io/jaxb-v2/doc/user-guide/ch05.html#xmldecl" rel="nofollow noreferrer">JAXB 2.2.11 documentation</a>  where the property is described as <code>com.sun.xml.bind.xmlHeaders</code> but when I try it:</p>
  <pre><code>javax.xml.bind.PropertyException: name: com.sun.xml.bind.xmlHeaders
  </code></pre>
  <p>But using <code>com.sun.xml.internal.bind.xmlHeaders</code> (note: <code>internal</code>) works.</p>
  <p>So my question is really about the rationale of this. Am I looking at the wrong documentation? Where is the <code>internal</code> coming from?</p>
  <pre><code>public static void main(String[] args) throws JAXBException {
      MyElement myxml = new MyElement();
      JAXBContext context = JAXBContext.newInstance(MyElement.class);
      Marshaller marshaller = context.createMarshaller();
      marshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE);
  
      marshaller.setProperty(&quot;com.sun.xml.bind.xmlHeaders&quot;,&quot;&quot;);
      //marshaller.setProperty(&quot;com.sun.xml.internal.bind.xmlHeaders&quot;,&quot;&lt;DOCTYPE&gt;&quot;);
  
      marshaller.marshal(myxml, System.out);
  }
  </code></pre>