• +91 9723535972
  • info@interviewmaterial.com

Hibernate Interview Questions and Answers

Question - What happens when the no-args constructor is absent in the Entity bean?

Answer -

Hibernate framework internally uses Reflection API for creating entity bean instances when get() or load() methods are called. The method Class.newInstance() is used which requires a no-args constructor to be present. When we don't have this constructor in the entity beans, then hibernate fails to instantiate the bean and hence it throws HibernateException.

Comment(S)

Show all Coment

Leave a Comment




NCERT Solutions

 

Share your email for latest updates

Name:
Email:

Our partners