Buying Options
Harnessing Hibernate
Print $39.99
Add to Cart
Print+Ebook $43.99
Add to Cart
Ebook $31.99
Add to Cart
Safari Books Online
Add to Cart
What is this?
Print £30.99
Add to Cart
What is this?
Description
This guide is an ideal introduction to Hibernate, the framework that lets Java developers work with information from a relational database easily and efficiently. Databases are a very different world than Java objects, and with Hibernate, bridging them is significantly easier. This new edition lets you explore the system, from download and configuration through a series of projects that demonstrate how to accomplish a variety of practical goals.

Full Description
Table of Contents
  1. Hibernate in a Hurry

    1. Chapter 1 Installation and Setup

      1. Getting an Ant Distribution
      2. Check Your Java Version
      3. Getting the Maven Tasks for Ant
      4. Installing the Maven Tasks for Ant
      5. Using the HSQLDB Database Engine
      6. Using Hibernate Core
      7. Setting Up a Project Hierarchy
    2. Chapter 2 Introduction to Mapping

      1. Writing a Mapping Document
      2. Generating Some Class
      3. Cooking Up a Schema
    3. Chapter 3 Harnessing Hibernate

      1. Configuring Hibernate
      2. Creating Persistent Objects
      3. Finding Persistent Objects
      4. Better Ways to Build Queries
    4. Chapter 4 Collections and Associations

      1. Mapping Collections
      2. Persisting Collections
      3. Retrieving Collections
      4. Using Bidirectional Associations
      5. Working with Simpler Collections
    5. Chapter 5 Richer Associations

      1. Eager and Lazy Associations
      2. Ordered Collections
      3. Augmenting Associations in Collections
      4. Lifecycle Associations
      5. Reflexive Associations
    6. Chapter 6 Custom Value Types

      1. Defining a User Type
      2. Defining a Persistent Enumerated Type
      3. Using a Custom Type Mapping
      4. Working with Persistent Enumerations
      5. Building a Composite User Type
    7. Chapter 7 The Annotations Alternative

      1. Hibernate Annotations
      2. Annotating Model Objects
      3. An Alternate Approach
    8. Chapter 8 Criteria Queries

      1. Using Simple Criteria
      2. Compounding Criteria
      3. Projection and Aggregation with Criteria
      4. Applying Criteria to Associations
      5. Querying by Example
      6. Property-Oriented Criteria Factories
    9. Chapter 9 A Look at HQL

      1. Writing HQL Queries
      2. Selecting Properties and Pieces
      3. Sorting
      4. Working with Aggregate Values
      5. Writing Native SQL Queries
  2. Playing Nice with Others

    1. Chapter 10 Connecting Hibernate to MySQL

      1. Setting Up a MySQL Database
      2. Connecting to MySQL
      3. Trying It Out
      4. Looking at the Data
    2. Chapter 11 Hibernate and Eclipse: Really Using the Hibernate Tools

      1. Installing the Hibernate Tools in Eclipse
      2. Creating a Hibernate Console Configuration
      3. More Editing Support
      4. The Hibernate Console Perspective
      5. Code Generation
      6. Mapping Diagrams
    3. Chapter 12 Maven in More Depth

      1. What Is Maven?
      2. Installing Maven
      3. Building, Testing, and Running a Project
      4. Generating IDE Project Files using Maven
      5. Generating Reports with Maven
      6. A Maven Project Object Model
      7. The Maven Build Lifecycle
      8. Using the Maven Hibernate3 Plug-in
      9. Becoming a Maven Maven
    4. Chapter 13 Put a Spring in your Step: Hibernate with Spring

      1. What Is Spring?
      2. Writing a Data Access Object
      3. Creating an Application Context
      4. Putting It All Together
    5. Chapter 14 The Finishing Touch: Stripes with Spring and Hibernate

      1. Earn Your Stripes
      2. Prepare Tomcat
      3. Create the Web Application
      4. Add Stripes
      5. Dealing with Associations
  1. Appendix Hibernate Types

    1. Basic Types

    2. Custom Value Types

    3. “Any” Type Mappings

    4. All Types

  2. Appendix The Criteria API

    1. The Criterion Factory

    2. The Projection Factory

    3. The Order Factory

    4. The Property Factory

  3. Appendix Hibernate SQL Dialects

    1. Getting Fluent in the Local SQL

  4. Appendix Spring Transaction Support

    1. Using the Spring Framework’s Transactional Annotation

    2. Using a JTA Transaction Manager

  5. Appendix Where to Go Next

    1. Online Manuals

    2. Books

    3. Source Code

    4. Dealing with Newer Releases

    5. Getting Involved

  6. Colophon

View Full Table of Contents
Product Details
Title:
Harnessing Hibernate
By:
James Elliott, Timothy M. O'Brien, Ryan Fowler
Publisher:
O'Reilly Media
Formats:
  • Print
  • Ebook
  • Safari Books Online
Print Release:
April 2008
Ebook Release:
December 2008
Pages:
384
Print ISBN:
978-0-596-51772-4
| ISBN 10:
0-596-51772-6
Ebook ISBN:
978-0-596-15948-1
| ISBN 10:
0-596-15948-X
Customer Reviews
About the Authors
  1. James Elliott

    James Elliott is a senior software engineer at Berbee, with fifteen years' professional experience as a systems developer. He started designing with objects well before work environments made it convenient, and has a passion for building high-quality Java tools and frameworks to simplify the tasks of other developers.

    View James Elliott's full profile page.

  2. Timothy M. O'Brien

    Tim is a professional singer/programmer living and working in the Chicago area. He prefers Emacs to vi. Tim discovered programming on a TRS-80, and went on to study (and subsequently forget) Electrical Engineering at UVA. In his free time Tim likes to sleep, study music, build toys with microcontrollers, and participate in open source projects. Tim is active in the Jakarta Commons.

    View Timothy M. O'Brien's full profile page.

  3. Ryan Fowler

    Ryan Fowler is a software engineer at Berbee in Madison, WI. He programmed Basic on Apple II machines for a while in elementary school at St. Stephen School in Grand Rapids, MI. He returned to coding in the computer science department at Alma College in Alma, MI while earning his bachelor's degree. Ryan skis, sails and rounds life out with some guitar playing when there's no snow or wind.

    View Ryan Fowler's full profile page.

Colophon

The animal on the cover of Harnessing Hibernate is a hedgehog, a small mammal in the family Erinaceinae. There are 16 hedgehog species in 5 genera, found throughout parts of Europe, Asia, Africa, and New Zealand. Some of these species are: the four-toed hedgehog (south-Saharan Africa); the long-eared hedgehog (Central Asia); the desert hedgehog (Africa and the Middle East); and the bare-bellied hedgehog (India). The different species vary in size, measuring 5 to 12 inches long and weighing 15 to 40 ounces. The most common domesticated hedgehog, known as the four-toed or African pygmy hedgehog, is smaller than its European cousins and has become a popular pet in many countries. The name hedgehog first came into use in the mid-15th century--"hedge" because it roots through undergrowth, and "hog" because of its pig-like snout. Hedgehogs are also known as urchins, hedgepigs, and furze-pigs.

The hedgehog's most distinctive feature is its spines, which grow everywhere on its body except its face, legs, and belly. When threatened, it rolls into a tight ball so that all of its spines point outward, presenting a barbed surface to predators. These spines are stiff, hollow hairs made of keratin and are very strong. Unlike a porcupine's quills, they do not fall out, except when a hedgehog sheds its baby spines during a process known as "quilling."

Hedgehogs eat small invertebrates such as frogs, slugs, and earthworms. Some hedgehogs have immunity to toxins and can eat bees, wasps, and venomous snakes. Being nocturnal, they sleep for most of the day in grass or under rocks or in holes in the ground. Although all hedgehogs can hibernate, not all do-hibernation depends on factors such as location, temperature, and abundance of food. In England, Bonfire Night celebrations on November 5th pose a particular risk to hedgehogs, who often sleep in the wood piles used for bonfires. Wildlife protection groups now warn the public to inspect their wood piles before lighting fires in order to protect hibernating hedgehogs.

The cover image is from J. G. Wood's Animate Creation. The cover font is Adobe ITC Garamond. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSansMonoCondensed.

  • Book cover of Harnessing Hibernate