Hibernate Quickly
Patrick Peak and Nick Heudecker
  • August 2005
  • ISBN 9781932394412
  • 456 pages

I highly recommend this book.

Christopher Haupt, Senior Engineering Manager, Adobe Systems Inc.

Positioned as a layer between the application and the database, Hibernate is a powerful object/relational persistence and query service for Java. It takes care of automating a tedious task: the manual bridging of the gap between object oriented code and the relational database. Hibernate Quickly gives you all you need to start working with Hibernate now.

About the book

The book focuses on the 20% you need 80% of the time. The pages saved are used to introduce you to the Hibernate "ecosystem": how Hibernate can work with other common development tools and frameworks like XDoclet, Struts, Webwork, Spring, and Tapestry.

The book builds its code examples incrementally, introducing new concepts as it goes. It covers Hibernate's many, useful configuration and design options, breaking a complex subject into digestible pieces. With a gradual "crawl-walk-run" approach, the book teaches you what Hibernate is, what it can do, and how you can work with it effectively.

Table of Contents detailed table of contents



about this book

about the cover illustration

1. Why Hibernate?

1.1. Understanding object persistence

1.2. Using direct JDBC

1.3. Persistence with Hibernate

1.4. Summary

2. Installing and building projects with Ant

2.1. Getting a Hibernate distribution

2.2. Installing Ant

2.3. Setting up a database

2.4. Setting up a project

2.5. Habits of highly effective build files

2.6. Summary

3. Hibernate basics

3.1. Configuring Hibernate

3.2. Creating mapping definitions

3.3. Building the SessionFactory

3.4. Persisting objects

3.5. Retrieving objects

3.6. The Session cache

3.7. Advanced configuration

3.8. Inheritance

3.9. Summary

4. Associations and components

4.1. Associations

4.2. Building tables with Ant and SchemaExport

4.3. Components

4.4. Summary

5. Collections and custom types

5.1. Persisting collections and arrays

5.2. Implementing custom types

5.3. Summary

6. Querying persistent objects

6.1. Using HQL

6.2. Querying objects with HQL

6.3. Criteria queries

6.4. Stored procedures

6.5. Hibern8IDE

6.6. Summary

7. Organizing with Spring and data access objects

7.1. The ubiquitous DAO pattern

7.2. Analyzing the DAO

7.3. The Layer Supertype pattern

7.4. The Spring Framework

7.5. Summary

8. Web frameworks: WebWork, Struts, and Tapestry

8.1. Defining the application

8.2. A quick overview of MVC

8.3. Decoupling Hibernate from the web layer

8.4. WebWork

8.5. Struts

8.6. Tapestry

8.7. Hibernate in the view layer

8.8. Summary

9. Hibernating with XDoclet

9.1. Essential XDoclet

9.2. Making single objects persistent

9.3. Basic relationships

9.4. Building collections

9.5. Going where no XDoclet has gone before

9.6. Generating the hibernate.cfg.xml file

9.7. Summary

10. Unit testing with JUnit and DBUnit

10.1. Introduction to unit testing

10.2. JUnit

10.3. Testing the persistence layer

10.4. Testing with DBUnit

10.5. Summary

11. What’s new in Hibernate 3

11.1. Filters

11.2. Mapping improvements

11.3. Dynamic classes

11.4. Annotations

11.5. Stored procedures and SQL

11.6. Persistence events

11.7. Lazy properties

11.8. Summary

Appendix A: The complete Hibernate mapping catalog

A.1. A sample association

A.2. Many-to-one

A.3. One-to-one

A.4. Components

A.5. Set: one-to-many

A.6. Set: many-to-many

A.7. Lists

A.8. Maps

A.9. Arrays

A.10. Bags

A.11. Subclasses

A.12. Summary


What's inside

  • Writing mapping files and creating associations
  • Hibernate with XDoclet, Struts, Webwork, Spring, and Tapestry
  • Querying persistent objects
  • Using web application architecture
  • Testing with JUnit and Ant

About the authors

Patrick Peak is the CTO of a firm that emphasizes open source frameworks and tools for competitive advantage. He lives in Arlington, Virginia.

Nick Heudecker has large scale development experience with projects for Fortune 500 clients, the media, and government. He lives in Chicago, Illinois.

placing your order...

Don't refresh or navigate away from the page.
eBook $25.19 $35.99 PDF only
Hibernate Quickly (eBook) added to cart
continue shopping
go to cart

Prices displayed in rupees will be charged in USD when you check out.

FREE domestic shipping on three or more pBooks