title: "http://annox.dev.java.net" customizations require the "-Xannotate" switch
body: <p>I am trying to run a real schema through hyperjaxb.  I have tested the schema repeatedly using jaxb, and jaxb imports the schema correctly every time.  However, when I try to get hyperjaxb to generate hibernate-annotated java classes from the same schema, I get the following error:  </p>
  
  <pre><code>[ERROR] Error while parsing schema(s).Location [ file:/C:/path/to/src/main/resources/schema.xsd{4,32}].
  org.xml.sax.SAXParseException; systemId: file:/C:/path/to/src/main/resources/schema.xsd;  
  lineNumber: 4; columnNumber: 32; 
  Using "http://annox.dev.java.net" customizations requires the "-Xannotate" switch 
  to enable this plug-in.
  </code></pre>
  
  <p>I have googled this error message and read other postings about it, but have not found any clean instructions for resolving it.  The closest I have found is <a href="http://confluence.highsource.org/display/J2B/Annotate+Plugin" rel="nofollow">this article</a>, which says that the annox plugin <code>is activated by the -Xannotate command-line argument</code>.  </p>
  
  <p>I read <a href="https://github.com/highsource/jaxb2-annotate-plugin" rel="nofollow">this link</a>, but adding the following to the xsd file did not eliminate the error, probably because the <code>xsd</code> does not use the <code>jaxb</code> prefix anywhere.</p>
  
  <pre><code>xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
  jaxb:version="2.1" 
  xmlns:annox="http://annox.dev.java.net" 
  jaxb:extensionBindingPrefixes="annox"
  </code></pre>
  
  <p>I have uploaded a zip file containing all the relevant materials to quickly reproduce the problem <a href="https://jumpshare.com/v/A6C8C0qcGp0PxXykfZKA?b=D09y0Bld0v99GBP7kASX" rel="nofollow">to this link</a>.  It is a zip file of the project including the intended schema.  All you have to do to reproduce the problem is navigate the command line to the root directory of the unzipped project and type <code>mvn clean install</code> to reproduce the error.</p>
  
  <p><strong>How can I resolve this error?</strong>  </p>
  
  <hr>
  
  <h2><strong>EDIT:</strong></h2>
  
  <p>I have experimented with adding the following to plugin configuration in pom.xml, but so far have not had success.  </p>
  
  <pre><code>&lt;args&gt;
      &lt;arg&gt;-Xannotate&lt;/arg&gt;
  &lt;/args&gt;  
  </code></pre>
  
  <hr>
  
  <h2><strong>SECOND EDIT:</strong></h2>
  
  <p>I added @lexicore 's suggestions to the <code>pom.xml</code>, but the result is a <code>null pointer exception</code>, which you can read <a href="https://jumpshare.com/v/EmefCEUcNAE1srSfkGbN?b=D09y0Bld0v99GBP7kASX" rel="nofollow">by clicking on this link</a>.  To promote easier use of <code>hyperjaxb</code> by others, I am including the full current <code>pom.xml</code> <a href="https://jumpshare.com/v/0ZkIHyMYeFRIYqDZrGLS?b=D09y0Bld0v99GBP7kASX" rel="nofollow">at this link</a>.  Together, this revised <code>pom.xml</code> and the above zip file are enough to recreate the problem in a few minutes. Is this a configuration problem or a bug?</p>