[JBoss JIRA] (FORGE-1892) REST endpoint should also consume/produce JSon
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/FORGE-1892?page=com.atlassian.jira.plugin... ]
Antonio Goncalves commented on FORGE-1892:
------------------------------------------
Yes, I need XML and JSon actually. It would be good to be able to specify a list of content types
> REST endpoint should also consume/produce JSon
> ----------------------------------------------
>
> Key: FORGE-1892
> URL: https://issues.jboss.org/browse/FORGE-1892
> Project: Forge
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Components: Scaffold
> Affects Versions: 2.6.0.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> When a REST endoint is generated, there is only support for XML MIMETYPE
> {code}
> @GET
> @Produces("application/xml")
> public List<Book> listAll(@QueryParam("start") Integer startPosition, @QueryParam("max") Integer maxResult)
> {code}
> It would be good to have both XML and JSON
> {code}
> @GET
> @Produces({"application/xml","application/json"})
> public List<Book> listAll(@QueryParam("start") Integer startPosition, @QueryParam("max") Integer maxResult)
> {code}
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 10 months
[JBoss JIRA] (FORGE-1892) REST endpoint should also consume/produce JSon
by Vineet Reynolds (JIRA)
[ https://issues.jboss.org/browse/FORGE-1892?page=com.atlassian.jira.plugin... ]
Vineet Reynolds commented on FORGE-1892:
----------------------------------------
The {{--contentType}} flag can be used to specify {{application/json}}, but only either content type can be specified. If I'm not wrong, you need both?
> REST endpoint should also consume/produce JSon
> ----------------------------------------------
>
> Key: FORGE-1892
> URL: https://issues.jboss.org/browse/FORGE-1892
> Project: Forge
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Components: Scaffold
> Affects Versions: 2.6.0.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> When a REST endoint is generated, there is only support for XML MIMETYPE
> {code}
> @GET
> @Produces("application/xml")
> public List<Book> listAll(@QueryParam("start") Integer startPosition, @QueryParam("max") Integer maxResult)
> {code}
> It would be good to have both XML and JSON
> {code}
> @GET
> @Produces({"application/xml","application/json"})
> public List<Book> listAll(@QueryParam("start") Integer startPosition, @QueryParam("max") Integer maxResult)
> {code}
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 10 months