You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by "Scott Eade (JIRA)" <ji...@apache.org> on 2006/06/20 08:14:30 UTC

[jira] Updated: (TRB-11) Intake, mapToObject, and using Interfaces

     [ http://issues.apache.org/jira/browse/TRB-11?page=all ]

Scott Eade updated TRB-11:
--------------------------

    Attachment: Group.interfaces.diffs

> Intake, mapToObject, and using Interfaces
> -----------------------------------------
>
>          Key: TRB-11
>          URL: http://issues.apache.org/jira/browse/TRB-11
>      Project: Turbine
>         Type: Improvement

>   Components: Fulcrum
>  Environment: PC / RedHat
>     Reporter: Scott Eade
>     Priority: Minor
>  Attachments: Group.interfaces.diffs
>
> This is/was bugzilla bug #12661. Moving it to Scarab.
> Short version: Intake won't use interfaces for the mapTo 
> Attached is a patch that provides this.
> Details:
> I've been using Intake quite successfully until a recent change I
>  made in my code. The mapTo object is a configuration object that
>  does the PropertyChange and VetoableChange JavaBean pattern and it
>  got rather tedious. So I switched to using an dynamic Proxy
> (java.lang.reflect.Proxy). Testing with regular Java classes it works
> great.
> Following the code, Intake.mapTo(Retrievable) uses the Retrievable's
> classname (and superclasses) as the key into a Map for fields (and
> ultimately their setter/getters. The dynamic Proxy is initialized by
> providing an interface. Sun's implementation in the JDK auto-creates
> a new class that implements the interface as well as extending Object
> while naming the class Proxy0 (as in zero, not oh). Therefore, the
> proxied object ends up with a name not known to Intake yet
> implementing an interface. So Group.init(Retrievable)'s logic of
> chasing the classes and superclasses won't find any fields for the
> class.
> Wow, from bugzilla to Scarab to JIRA.  Issue raised by Evan Koffler (evan@codezodiac.com).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org