March 2015
Intermediate to advanced
284 pages
6h 13m
English
CHAPTER 3
![]()
Component Mapping
Hibernate makes it easy to employ a fine-grained domain model so you can have more classes than tables. In other words, you can map a single record in a table to more than one class by having one Entity class type; the others should be Value class types.
Hibernate classifies objects as either entity object types or value object types. An entity object type is an independent entity and has its own life cycle. It has its own primary key and hence its own database identity. A value object type doesn’t have an identifier. A value object type belongs to an entity and is bound by the life cycle of the owning entity instance. ...
Read now
Unlock full access