Possibly you can get some love registering a DynamicPropertyHandler class via 
JXPathIntrospector.registerDynamicClass(...).

-Matt

--- On Mon, 3/16/09, Andrew Hughes <ahhug...@gmail.com> wrote:

> From: Andrew Hughes <ahhug...@gmail.com>
> Subject: [JXPath][BeanUtils] External Bean PropertyDescriptor?
> To: "Commons Users List" <user@commons.apache.org>
> Date: Monday, March 16, 2009, 9:53 PM
> Hi,
> I am trying to use JXPath on a not-so-bean complient
> "Something.java" class.
> The 
> JXBeanInfo<http://commons.apache.org/jxpath/apidocs/org/apache/commons/jxpath/JXPathBeanInfo.html#getDynamicPropertyHandlerClass()>
> method
> getPropertyDescriptor stipulates that I return a
> PropertyDescriptor<http://java.sun.com/j2se/1.3/docs/api/java/beans/PropertyDescriptor.html>
> in
> order to allow JXPath to get/set the properties within
> "Something.java". The
> problem is that the not-so-bean-complient "Something.java"
> class doesn't
> have get/set equivalent methods. It actually has iterator()
> and from that
> you can then iterate over all "properties" and work with
> them directly.
> 
> Can I somehow inject a method implementation or proxy
> object outside of
> "Something.java" that will provide the required logic/code
> to perform the
> get/set operation on Something.java's properties?
> 
> Any help would be much appreciated :)
> 


      

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

Reply via email to