Hibernate Introduction (introductory)

 

What is Hibernate

Hibernate object-relational mapping framework is an open source, it had a very lightweight JDBC object package, it will POJO mapping relationship with a database table, it is a fully automated orm framework, hibernate can automatically generate SQL statements, automatically, so that the Java programmer can use arbitrary object programming thinking to manipulate the database. Hibernate can be used in any occasion using JDBC, Java can be used in both client program can also be used in Servlet / JSP Web application, the most revolutionary is, Hibernate can replace the CMP in EJB applications in architecture JaveEE complete data persistence task.

What is ORM

Object-Relational Mapping (English: Object Relation Mapping, referred to as the ORM, or O / RM, or O / R mapping), is a program technology, for conversion between data in object-oriented programming language, different types of systems.

Object - relational mapping, along with object-oriented software development methods and the development generated. Object-oriented development approach is to mainstream development approach today's enterprise-class application development environment, a relational database is the main data storage system enterprise application environments permanent storage of data. Object and relational data are two forms of business entities in the form of business entity performance object in memory, the performance of relational data in the database. An association and inheritance relationships between objects in memory, and in the database, relational data can not be directly expressed many to many associations and inheritance. Accordingly, the object - relational mapping (ORM) system is generally present in the form of middleware, the main procedures for mapping objects to a relational database data. Simplicity ORM model simplifies the database query process. Use ORM query tool, users can access the desired data without having to understand the underlying structure of the database.

 

Briefly, we use our ORM object (or class) may be mapped to, so that we can go to complete the operation on the operation target table.

 

Why Hibernate framework

the reason:

  1. Hibernate a JDBC database access code do packaging greatly simplifies the data access layer tedious repetitive code.
  2. Hibernate is a JDBC-based persistence framework mainstream, is an excellent ORM implementation, simplifying the dao layer coding its large degree.
  3. Summary: Hibernate framework mainstream enterprise development, flexibility mapped very well. It supports many relational database.

Hiberate frame learning objectives

Summarized as:

  • Hiberate master basic configurations - the development environment to build Hiberate
  • Hiberate grasp of how to use common API-- Hiberate framework for development
  • Hiberate master association map - solving the relationship between the table and the table, there are 1: n-(one to many), 1: 1 (one to one), m: n (many) relationship
  • Hiberate grasp of search methods - that is, master Hiberate inquiry
  • Master Hiberate optimized way - that is, to improve the efficiency of Hiberate

 

Guess you like

Origin www.cnblogs.com/lucky1024/p/11023052.html