tomba wrote:
If you can't live with the warning or find it annoying, you can either switch it off in eclipse or just add the following just above the start of your method:
@suppresswarnings("unchecked")
It's a rather normal thing to do as API's (such as Hibernate's) try to keep backward compatibility and it will therefore not be possible to fix the unchecked type warnings.
Thanks for the replies Farzad and tomba.
For now,I have used @SuppressWarnings("unchecked") to supress the eclipse warning messages. I will also learn about JPA as Farzad suggested.
Thanks guys, you have been of great help. :)