wish Jesse to fix the bug in T5.

Jun Tsai

2007/6/26, Jesse Kuhnert <[EMAIL PROTECTED]>:

I don't know if this helps or not, but I got generics working in a very
limited way with 4.1.x in that I do all the type lookup work
manually...(this probably won't work for this use case but thought I'd
throw
it out just in case it does, even this breaks down in many places)


http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/enhance/GenericsMethodSignatureImpl.java?view=markup

http://svn.apache.org/viewvc/tapestry/tapestry4/trunk/tapestry-framework/src/java/org/apache/tapestry/enhance/GenericsClassInspectorImpl.java?view=markup

On 6/26/07, Francois Armand <[EMAIL PROTECTED]> wrote:
>
> Francois Armand wrote:
> > Actually, it's not really an acceptable solution, but the sole
> > workaround I know (if somebody as another idea, I would be glad to use
> > it).
> Well, this sentence is not true.
> You may ask users to implement a "factory" interface for Class they
> intend to use as parameter type for the bean component source object.
>
> The interface should be like that :
> 8<----------------------------------
> interface Factory<T> {
>     T create();
> }
> 8<----------------------------------
> And then you just call the create() implementation.
>
> The problem is that that "solution" is very error prone :  the interface
> base implementation has to be overridden by each subclass or you will
> end with the same type problem.
> So, it seems to be a wore solution than the other one...
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com




--
Welcome to China Java Users Group(CNJUG).
http://cnjug.dev.java.net

Reply via email to