Note that there are some explanatory texts on larger screens.

plurals
  1. POXmlJavaTypeAdapter and enunciate?
    primarykey
    data
    text
    <p>I'm having a hard time running Enunciate on my project. The project is a multi-module maven project, available from <a href="https://svn.opentripplanner.org/trunk" rel="nofollow">https://svn.opentripplanner.org/trunk</a> . All I want out of enunciate is API docs. Nothing else. We used to have this working via Maven and Hudson, but it broke a while ago, and the person who set it up isn't available. Really, I would prefer to do this via the command-line interface, but if someone has a Maven solution, I'll take it.</p> <p>My enunciate command-line is:</p> <pre><code>/home/novalis/otp/enunciate-1.23/bin/enunciate -v -f /home/novalis/otp/workspace/opentripplanner/opentripplanner-api-webapp/enunciate.xml `find /home/novalis/otp/workspace/opentripplanner/ -name *.java -type f |grep -v /test/` </code></pre> <p>My enunciate.xml looks like this:</p> <pre><code>&lt;enunciate xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://enunciate.codehaus.org/schemas/enunciate-1.17.xsd"&gt; &lt;services&gt; &lt;rest&gt; &lt;content-types&gt; &lt;content-type type="text/plain" id="txt"/&gt; &lt;/content-types&gt; &lt;/rest&gt; &lt;/services&gt; &lt;modules&gt; &lt;c disabled="true"/&gt; &lt;obj-c disabled="true"/&gt; &lt;csharp disabled="true"/&gt; &lt;jaxws-client disabled="true"/&gt; &lt;docs title="OpenTripPlanner API" base="src/main/resources/docs-theme"/&gt; &lt;/modules&gt; &lt;/enunciate&gt; </code></pre> <p>And my enunciate output is:</p> <pre><code>initializing enunciate. invoking enunciate:generate step... error: Could not create declaration for annotation type Autowire error: Could not create declaration for annotation type Component error: Could not create declaration for annotation type Autowired error: Could not create declaration for annotation type Required 4 errors Exception in thread "main" org.codehaus.enunciate.contract.validation.ValidationException: /home/novalis/otp/workspace/opentripplanner/opentripplanner-routing/src/main/java/org/opentripplanner/routing/patch/StopNotePatch.java:58: stop: adapter org.opentripplanner.routing.patch.AgencyAndIdAdapter does not adapt AgencyAndId at org.codehaus.enunciate.contract.jaxb.adapters.AdapterUtil.findAdapterType(AdapterUtil.java:134) at org.codehaus.enunciate.contract.jaxb.adapters.AdapterUtil.findAdapterType(AdapterUtil.java:57) [more traceback snipped] </code></pre> <hr> <p>AgencyAndIdAdapter <em>does</em> adapt AgencyAndId. The actual code works just fine when I run it. I've tried building a tiny test case with XmlAdapter adapting a random Java class (JPanel), and it works fine. So I can't figure out how to reduce the problem further. </p> <p>I don't think the errors about Autowire/Component/etc are causing this, because if I exclude all files that contain those annotations (|xargs grep -L 'Autowire|Component|Request' just before the closing backtick), I still get the remainder of the error. Still, it would be good to fix those, too.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload