Thanks for the information, we don't have to put the data on the top of the 
stack, but we cannot do a stack.put("myObj", x) since ValueStack doesn't have 
the put method besides push. Our interceptor needs to place the information 
holder such as skin holder into the stack before calling the action class to 
return JSON object like the following example below:
@Results({ 
        @Result(name = "success", type = "json", params = {
                        "includeProperties",
                        "provinces\\[\\d+\\]\\.label," + 
"provinces\\[\\d+\\]\\.provinceCode" }),

Do you have some information/approach for enabling the above when using 
struts2-json-plugin-2.2.3.jar ? Struts 2.2.1 works fine. Since we cannot use 
stack.put() method, what would be some ways to do this ?

Thanks.
Jerry

-----Original Message-----
From: Chris Pratt [mailto:thechrispr...@gmail.com] 
Sent: Wednesday, May 18, 2011 2:53 PM
To: Struts Developers List
Subject: RE: Issue Reporting: problem with findRootObject process in 
struts2-json-plugin-2.2.3.jar

I believe that was the entire purpose of the change.  To allow interceptors 
(especially the ModelDriven interceptor) to provide the data for a JSON result.

Do your interceptors have to put the data on the top of the stack?  You could 
just do a stack.put("myObj",x) instead of a stack.push(x), then reference the 
value using the hash operator in your view (i.e. #myObj).
  (*Chris*)
On May 18, 2011 2:34 PM, "Jerry Yuan" <jy...@trionworlds.com> wrote:

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org

Reply via email to