TAILIEUCHUNG - Hibernate Tutorial 02

Open “Java - Build Path - User Libraries” in the “Preferences” page, add a custom library “Hibernate 3” and add the following jars to it: | Hibernate Tutorial 02 Hibernate Basics By Gary Mak hibernatetutorials@ September 2006 1. Installing Hibernate Hibernate is a powerful Object Relational Mapping framework for developing Java applications. You can go to http and download Hibernate Core . After downloading the compressed hibernate distribution extract it to an arbitrary directory say C . 2. Configuring Eclipse . Creating Hibernate User Library Open Java - Build Path - User Libraries in the Preferences page add a custom library Hibernate 3 and add the following jars to it Hibernate_Install_Dir ar Hibernate_Install_Dir lib ar Hibernate_Install_Dir lib Hibernate_Install_Dir lib Hibernate_Install_Dir lib Hibernate_Install_Dir lib ar Hibernate_Install_Dir lib ar Hibernate_Install_Dir lib ar Hibernate_Install_Dir lib Hibernate_Install_Dir lib Hibernate_Install_Dir lib Then add this Hibernate 3 user library to your project build path. 3. Creating Mapping Definitions For the first step we ask Hibernate to retrieve and persist the book objects for us. For simplicity let s ignore the publisher and chapters at this moment. We create a XML file at the same package as our Book class. This file is called the Mapping Definition for the Book class. The book objects are called Persistent Objects or Entities for they can be persisted in database and represent the real world entities. Page 1 of 8 xml version encoding UTF-8 DOCTYPE hibernate-mapping PUBLIC - Hibernate Hibernate Mapping DTD EN http hibernate-mapping package class name Book table BOOK id name isbn type string column ISBN property name name type string column BOOK_NAME property name publishDate type date column PUBLISH_DATE property name price type int column PRICE class .

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.