You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First, Great job, we use your generic dao in our project and it's very handy !
What steps will reproduce the problem?
1. create an implementation of GenericDAOImpl<ModelClass, IdClass> named
ParentDao
2. extend ParentDao in ChildDao
3. new ChildDao();
What is the expected output? What do you see instead?
Constructor threw exception; nested exception is
java.lang.ClassCastException: java.lang.Class cannot be cast to
java.lang.reflect.ParameterizedType
What version of the product are you using? On what operating system?
Java 6 64 bits, ubuntu 8.10, but it's irrelevant.
Present in r590.
Please provide any additional information below.
It's a common issue with Generics. This blog entry shows a solution :
http://www.artima.com/weblogs/viewpost.jsp?thread=208860
Having the choice between an empty constructor (which would infer the
persistent class' type from the generic argument) and a contructor that
takes the persistent class as an argument would be a great solution if you
don't want to implement the whole solution :)
Thanks a lot !
Original issue reported on code.google.com by mathieu....@gmail.com on 30 Jul 2009 at 8:46
The text was updated successfully, but these errors were encountered:
Thanks for reporting and for the solution! I remember we had this problem back
in the
early stages but didn't get around to fixing it at the time.
I'll get this fix into the next release (0.5.1).
Original comment by dwolvert on 3 Aug 2009 at 12:19
Original issue reported on code.google.com by
mathieu....@gmail.com
on 30 Jul 2009 at 8:46The text was updated successfully, but these errors were encountered: