Home » JPA » Annotations » Class Modifiers

JPA Annotations for Classes

JPA defines three types of persistable classes which are set by the following annotations:

Chapter 2 of the ObjectDB manual explains these annotations in detail.

Entity and mapped super classes can be further configured by annotations that specify cache preferences and lifecycle event listener policy (as explained in chapter 3):

Another JPA class annotation defines an ID class:

ID classes are useful in representing composite primary keys as explained in the Primary Key section of the ObjectDB manual.