cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Francesco Chicchiriccò <ilgro...@apache.org>
Subject Re: swagger2feature do not see javadocs ?
Date Tue, 17 Jan 2017 13:08:22 GMT
On 17-jan-17, at 13:44, Vjacheslav V. Borisov slavb18@gmail.com wrote:

> Hi!
> 
> Playing with
> https://github.com/apache/cxf/tree/master/distribution/src/main/release/samples/jax_rs/spring_boot
> 
> Added Javadoc  to method sayHello
> 
>    /**
>     * sayHello doc
>     * @param a the a param
>     * @return
>     */
>    public String sayHello(String a) {
>        return "Hello2 " + a + ", Welcome to CXF RS Spring Boot World!!!";
>    }
> 
> And do not see this documentation  in swagger.json / api-docs
> 
> Is javadoc parsing  not implemented in swagger.json generation, or i am
> missing some switch?

The DefaultSwagger2Serializers class requires a JavadocProvider in order to be able to extract
info from Javadocs; use one the methods [1] to configure.

HTH
Regards.

[1] https://github.com/apache/cxf/blob/3.1.x-fixes/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java#L198-L217

-- 
Francesco Chicchiriccò

Tirasa - Open Source Excellence
http://www.tirasa.net/

Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/

Mime
View raw message