You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by David Canos <da...@gmail.com> on 2009/11/28 14:05:17 UTC
REST multiple return type problems
Hi guys
i'm using REST plugin in Struts 2.1.8.1
I'm using ModelDriven and also using a result (resultType stream) to output
some special cases like simple "true or false" coded manually in json.
It's working properly but if I define
<constant name="struts.rest.defaultExtension" value="json"/>
I *cannot use my own results*, it's always returning modeldriven object in
json!!
Another issue, how can we know in a method what is the contentType
(json,xhtml,xml,...) defined in the request?
We need it to manually code "true or false" results.
--
David CanĂ³s
www.david-canos.net