Advantages of Hibernate Framework

Advantages of  Hibernate Framework :

  • Hibernate has capability to generate primary keys automatically while storing the records into database.
  • Hibernate provide automatic table creation facility.
  • Hibernate framework supports Inheritance, Associations, Collections.
  • Hibernate has annotations facilities.
  • In hibernate if you save the subclass class object, then its super class object will also be stored into the database, that is hibernate supporting inheritance.
  • Hibernate provide caching technique through this, an application can increase its performance automatically.
  • Hibernate supports relationships such as One-To-Many,One-To-One, Many-To-Many-to-Many, Many-To-One
    it is also supports collections like list, set, map, bag.
  • In hibernate you only have Un-checked(Runtime) exceptions, so don’t need to write try-catch block, or throws. Because in hibernate has translator which converts checked to Un-checked.
  • Hibernate has its own query language, that is hibernate query language(HQL) which is database independent. So that if you will change the database, then your application will works properly due to HQL is database independent.
  • Pagination can use in hibernate is very simple.
  • Hibernate provides Dialect classes, so you don’t need to write sql specific queries in hibernate, instead use the methods provided by API.
Advertisements

What is Hibernate Framework

Hibernate Framework :

Hibernate framework is an ORM(Object Relational Mapping) tools which is used to map java class with database table name and class variable with database table’s column. It is open source(free of cost) anybody can download its jar from hibernate.org/orm/downloads/ and use.

Hibernate framework provide database specific Dialect which used to switch different database without code change in application. Through this a programmer don’t need to write database specific query.