Search

Hibernate Annotations

Historically both Hibernate Annotations and Hibernate EntityManager were versioned and released from Hibernate Core. As of Hibernate Core version 3.5. Eventually the documentation for all 3 will be consolidated as well.

Hibernate, like all other Object/Relational Mapping tools, requires metadata that governs the transformation of data from one representation to the other (and vice versa). As an option, you can now use JDK 5.0 annotations for object/relational mapping with Hibernate 3.2. You can use annotations in addition to or as a replacement of XML mapping metadata.

The Hibernate Annotations package includes:

  • Standardized Java Persistence and EJB 3.0 (JSR 220) object/relational mapping annotations
  • Hibernate-specific extension annotations for performance optimization and special mappings

You can use Hibernate extension annotations on top of standardized Java Persistence annotations to utilize all native Hibernate features.

Requirements: At a minimum, you need JDK 5.0 and Hibernate Core, but no application server or EJB 3.0 container. You can use Hibernate Core and Hibernate Annotations in any Java EE 5.0 or Java SE 5.0 environment.