Hibernate's ORM and hibernate

Source: Internet
Author: User

Orm:

ORM is object/relation Mapping, object/relational database mapping.

At present, the popular programming languages, such as Java, C #, and so on, are object-oriented programming languages, while the more mainstream database products, such as ORACLE,DB2, are relational databases. Between the programming language and the underlying database

This uncoordinated, spawned an ORM framework. The ORM framework can be seen as a bridge between programming languages and databases.

When we adopt the ORM framework, the application no longer accesses the underlying database directly, but instead works with persisted objects in an object-oriented manner (such as the creation of objects, modification of objects, deletion of objects), and the ORM framework

Object-oriented operations into the underlying SQL operations, using JDBC implemented in the ORM framework to manipulate the database.

Basic Mapping Method:

How to map persisted classes and data tables:

A persisted class corresponds to a data table

A row of records in the data table is mapped into an instance object of the corresponding persistence class

A column of field mappings in the data table is called the property of the instance object that corresponds to the persisted class (field)

As for how the ORM framework handles the transformation between the two, this is transparent to developers without the developer's concern.

The popular ORM Framework:

JPA:JPA itself is an ORM specification, not an ORM framework. It is the result of Java EE spec makers learning from the open source world. Compared to other open source ORM frameworks, the biggest advantage of JPA is that it is an official standard, so

With versatility. If the application Cheng for JPA programming, then the application's persistence layer technology can switch freely between the various ORM frameworks.

Hibernate: Currently the most popular open source ORM framework has been selected as a persistent layer solution for JBoss. Hibernate's clever design, excellent performance, and rich documentation are the reasons for its popularity.

IBATIS: Is not purely an ORM framework for object-oriented manipulation. Especially where data access is particularly flexible, ibatis is more flexible, allowing developers to write SQL statements directly.

Toplink:oracle Company's products.

Hibernate Overview:

Hibernate (hibernation) is a durable layer solution for lightweight Java EE applications, and hibernate not only manages the Java class-to-database table mappings (including Java data types to SQL data type mappings), but also provides data

The method of querying and retrieving data can significantly shorten the time to process data persistence using JDBC.

Hibernate's ORM and hibernate

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.