Exception in thread "main" java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType
at com.thalasoft.learnintouch.core.dao.hibernate.GenericHibernateDao.<init>(GenericHibernateDao.java:41)
at com.thalasoft.learnintouch.core.dao.hibernate.UserHibernateDao.<init>(UserHibernateDao.java:26)
at com.thalasoft.learnintouch.core.dao.h2.hibernate.UserCustomHibernateDao.<init>(UserCustomHibernateDao.java:17)
at com.thalasoft.learnintouch.core.exception.TestDemo.main(TestDemo.java:8)
at com.thalasoft.learnintouch.core.dao.hibernate.GenericHibernateDao.<init>(GenericHibernateDao.java:41)
There's your clue -- that's the line of code which throws the exception. It's in a constructor of the GenericHibernateDao class, at line 41 specifically. You haven't shown us that code. If you still don't see the problem when you look there, then go ahead and post the code for us to look at.