Using Eclipse to develop JPA QuickStart

Source: Internet
Author: User

The WTP project under Eclipse Engineering includes a new development view--JPA (Java persistence API).

The JPA (Java persistence API) is the new data persistence programming model introduced in EJB 3.0. JPA leverages annotations (Annotation) and object/relational mappings to provide a simpler and more easy-to-use way of programming for data persistence. OpenJPA is an implementation of the JPA standards provided by the Apache organization.

Dali JPA Tools is a plug-in that is launched by eclipse.org to support JPA project development, with the primary goal of providing visual tool support for users to develop and edit the mapping relationships of JPA entities in EJB 3.0. Dali is part of the Eclipse WTP (Web Tools Platform) toolset, a toolset provided by eclipse.org to support Web applications and Java EE application development.

The latest version of the current Dali is 1.0, which is part of WTP 2.0 and does not offer stand-alone downloads. Dali 1.0 supports Eclipse version 3.3 and WTP 2.0. All of the descriptions in this article are for the Dali 1.0 version. Dali also has a 0.5 version that can support Eclipse 3.2 and WTP 1.5, and Dali 0.5 and 1.0 are not significantly different in functionality and usage, so they can be an option for older versions of Eclipse and WTP users.

The Dali toolset provides a dedicated JPA perspective for user development of JPA applications, consisting primarily of Package Explorer, Data Source Explorer, JPA Structure, and JPA Details views, Package Exp Lorer is used to manage all JPA projects, the data Source Explorer view is used to manage database joins, and the JPA Structure and JPA Details views are the most important part of the JPA perspective for managing mapping between Java objects and databases Systems, inheritance between entities, association relationships, and primary key generation strategies for entities.

Steps to develop JPA with Dali:

1. Environment setting

Sets the JPA implementation used by Eclipse. The following figure:

2. A new JPA project for Dali-demo.

Related Article

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.