There is also a includeProperties that you can use, to select only the 
properties you want to expose through json.
Sent via BlackBerry from T-Mobile

-----Original Message-----
From: Daniel Ruan <danielr...@gmail.com>
Date: Thu, 3 Nov 2011 15:59:23 
To: Struts Users Mailing List<user@struts.apache.org>
Reply-To: "Struts Users Mailing List" <user@struts.apache.org>
Subject: Re: JSON Plugin to Include Parent Action's Properties

Thanks, everybody.

I tried ignoreHierarchy, but got a Java reflection exception. Even if it
worked, it would have include too many things I don't want.  According to
the documentation, it "... serialize properties in all base classes (up to
Object) ".

I could try to use the excludeProperties parameter, but there will be too
many properties to exclude.  In addition, if the super class is modified to
have additional properties, it may break the JSON code without my knowledge.

What I really wish is to be able to selectively include supper class
properties, like syntax like"MyAction1.name1, MyAction2.name2".

Cheers,
Daniel

Reply via email to