I am using Enunciate to generate documentation for RestEasy services inside multi-module Maven project. I have some problems with doc generation when trying to get description of response object atributes.
For instance, if my service is defined as:
@GET
@Path("access/account")
@Produces({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML })
Account getAccount(@Context HttpServletRequest hsr, @Context UriInfo info) throws RestApiException;
when the documentation is generated no atribute description is generated.
name type description
idProfile int (no documentation provided)
idLanguage int (no documentation provided)
idRegion int (no documentation provided)
userType string (no documentation provided)
In all response objects I get only (no documentation provided). One important think is that all response classes are in different Maven module that the services are. The response classes are situated in the UTIL module. The services are situated in EJB module.
The reason for the problem is definitely multi-module Maven project, because if I define a response object that class is in the EJB module too, the documentation is perfect (also the description is generated).
The reason and also the solution is described here: https://github.com/stoicflame/enunciate/wiki/Multi-Module-Projects-%28Version-1%29
Despite all I still don't know what to do exactly and what to set inside different poms (EJB and UTIL) to solve my problem.
Any help is apreciated.
So have you tried to "import" the Account
class as described in Multi-Module Projects?
<enunciate ...>
<api-import pattern="com.mycompany.Account" />
<api-import pattern="com.mycompany.*" />
...
</enunciate>