13.3 O/R mapping files
The following table describes the configuration of the O/R mapping files:
Tag name |
Occurrence pattern |
Description |
||||||
---|---|---|---|---|---|---|---|---|
Once |
Indicates the root tag. |
|||||||
0 or once |
Adds the description. |
|||||||
0 or once |
Specifies the definition related to the entire PersistenceUnit. |
|||||||
0 or once |
Specifies whether to control the mapping metadata of the persistence unit. |
|||||||
0 or once |
Specifies the default value of the persistence unit. |
|||||||
0 or once |
Defines the schema. |
|||||||
0 or once |
Defines the catalog. |
|||||||
0 or once |
Specifies the access type. |
|||||||
0 or once |
Adds the cascade persistence option. |
|||||||
0 or once |
Defines the default entity listener of the persistence unit. |
|||||||
0 or more times |
Specifies the entity listener. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
Specifies the class package described in the elements and attributes within the same mapping file. |
|||||||
0 or once |
Defines the schema. |
|||||||
0 or once |
Defines the catalog. |
|||||||
0 or once |
Defines the access method. |
|||||||
0 or more times |
Adds the sequence generator. |
|||||||
0 or more times |
Defines the table generator. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or more times |
Defines a named query. |
|||||||
Once |
Specifies the query string. |
|||||||
0 or more times |
Adds a hint to the query. |
|||||||
0 or more times |
Defines the named native query. |
|||||||
Once |
Specifies the query string. |
|||||||
0 or more times |
Adds a hint to the query. |
|||||||
0 or more times |
Defines the SQL result set mapping. |
|||||||
0 or more times |
Specifies the entity class used for mapping the native SQL query result. |
|||||||
0 or more times |
Specifies the field used for mapping the native SQL query result. |
|||||||
0 or more times |
Specifies the column used for mapping the native SQL query result. |
|||||||
0 or more times |
Defines the mapped superclass of the persistence unit. |
|||||||
0 or once |
Adds the description for the mapped superclass of the persistence unit. |
|||||||
0 or once |
Overwrites @IdClass specified in the mapped superclass. |
|||||||
0 or once |
Defines whether to control the default entity listener of the mapped superclass and the sub class. |
|||||||
0 or once |
Defines whether to control the superclass listener of the mapped superclass and the sub class. |
|||||||
0 or once |
Specifies the callback listener class. |
|||||||
0 or more times |
Specifies the entity listener. |
|||||||
0 or once |
Specifies the lifecycle callback method. |
|||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
Defines the lifecycle callback method using the corresponding annotations in the mapped superclass. |
|||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
The element is not defined. |
|||||||
0 or more times#1 |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once |
Specifies the strategy for generating the primary key value. |
|||||||
0 or once |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or once |
Adds the table generator. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Adds the sequence generator. |
|||||||
0 or once#1 |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times |
Overwrites the mapping of properties and fields. |
|||||||
Once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once#2 |
Specified when mapping to the Lob type. |
|||||||
0 or once#2 |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or once#2 |
Specified when mapping to the enumeration type. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times#3 |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once#3 |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the order to be applied when maintaining a relation in the collection. |
|||||||
0 or once |
Specifies the map key as the Map type relation. |
|||||||
0 or once#4 |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or more times#4 |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times#5 |
Specifies the primary key column used as external key to JOIN with other tables. |
|||||||
0 or more times#5 |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once#5 |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the order to be applied when maintaining a relation in the collection. |
|||||||
0 or once |
Specifies the map key as the Map type relation. |
|||||||
0 or once |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times |
Overwrites the mapping of properties and fields. |
|||||||
Once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times |
Defines the entities of the persistence unit. |
|||||||
0 or once |
Adds the description for the entities of the persistence unit. |
|||||||
0 or once |
Overwrites @Table (including default values) of the entity class. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or more times |
Overwrites all @SecondaryTable and @SecondaryTables (including default values) of the entity class. |
|||||||
0 or more times |
Overwrites all @PrimaryKeyJoinColumn and @PrimaryKeyJoinColumns (including default values) of the entity class. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or more times |
Overwrites all @PrimaryKeyJoinColumn and @PrimaryKeyJoinColumns (including default values) of the entity class. |
|||||||
0 or once |
Overwrites @IdClass specified in the entity class. |
|||||||
0 or once |
Overwrites @Inheritance (including default values) of the entity class. |
|||||||
0 or once |
Overwrites @DiscriminatorValue (including default values) of the entity class. |
|||||||
0 or once |
Overwrites @DiscriminatorColumn (including default values) of the entity class. |
|||||||
0 or once |
Specifies the settings for the sequence generator that creates the primary key. |
|||||||
0 or once |
Specifies the settings for the generator that creates the primary key. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or more times |
Defines a named query. |
|||||||
Once |
Specifies the query string. |
|||||||
0 or more times |
Adds a hint to the query. |
|||||||
0 or more times |
Defines the named native query. |
|||||||
Once |
Specifies the query string. |
|||||||
0 or more times |
Adds a hint to the query. |
|||||||
0 or more times |
Defines the mapping of the SQL results. |
|||||||
0 or more times |
Specifies the entity class used for mapping the native SQL query result. |
|||||||
0 or more times |
Specifies the field used for mapping the native SQL query result. |
|||||||
0 or more times |
Specifies the column used for mapping the native SQL query result. |
|||||||
0 or once |
Controls the default entity listeners of the entity class and the sub class. |
|||||||
0 or once |
Controls the superclass listeners of the entity class and the sub class. |
|||||||
0 or once |
Overwrites @EntityListeners of the entity class. |
|||||||
0 or more times |
Specifies the entity listener. |
|||||||
0 or once |
Overwrites the definition of the lifecycle callback method according to the corresponding annotations, in the mapped superclass. |
|||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
Overwrites the definition of the lifecycle callback method according to the corresponding annotations, in the entity class. |
|||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or once |
||||||||
0 or more times |
Added to the value defined in @AttributeOverride or @AttributeOverrides of the entity class. |
|||||||
Once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or more times |
Added to the value defined in @AssociationOverride or @AssociationOverrides of the entity class. |
|||||||
One or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once |
The element is not defined. |
|||||||
0 or more times#1 |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once |
Specifies the strategy for generating the primary key value. |
|||||||
0 or once |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or once |
Adds the table generator. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the settings for the sequence generator that creates the primary key. |
|||||||
0 or once#1 |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times |
Added to the value defined in @AttributeOverride or @AttributeOverrides of the entity class. |
|||||||
Once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once#2 |
Specified when mapping to the Lob type. |
|||||||
0 or once |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or once#2 |
Specified when mapping to the enumeration type. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times#4 |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once#4 |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the order to be applied when maintaining a relation in the collection. |
|||||||
0 or once |
Specifies the map key as the Map type relation. |
|||||||
0 or once#3 |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or more times#3 |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times#5 |
Overwrites all @PrimaryKeyJoinColumn and @PrimaryKeyJoinColumns (including default values) of the entity class. |
|||||||
0 or more times#5 |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or once#5 |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the order to be applied when maintaining a relation in the collection. |
|||||||
0 or once |
Specifies the map key as the Map type relation. |
|||||||
0 or once |
Specifies the join table to be used in many-to-many and the unilateral one-to-many relationships. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owner-side entity. |
|||||||
0 or more times |
Specifies the external key column of the join table corresponding to the owned-side entity. |
|||||||
0 or more times |
Adds a unique constraint to DDL. |
|||||||
One or more times |
Specifies the name of the column in which the unique constraint will be added. |
|||||||
0 or once |
Specifies the operations that you can cascade. |
|||||||
0 or once |
Cascades all the operations. |
|||||||
0 or once |
Cascades the persist operation. |
|||||||
0 or once |
Cascades the merge operation. |
|||||||
0 or once |
Cascades the remove operation. |
|||||||
0 or once |
Cascades the refresh operation. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times |
Added to the value defined in @AttributeOverride or @AttributeOverrides of the entity class. |
|||||||
Once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or more times |
Defines the embeddable class of the persistence unit. |
|||||||
0 or once |
Adds the description for the embeddable class of the persistence unit. |
|||||||
0 or once |
The element is not defined. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
|||||||
0 or once |
Specifies the column mapping for the properties of the Persistent field. |
|||||||
0 or once#2 |
Specified when mapping to the Lob type. |
|||||||
0 or once#2 |
Specified when mapping to the DATE, TIME, and TIMESTAMP type. |
|||||||
0 or once#2 |
Specified when mapping to the enumeration type. |
|||||||
0 or more times |
Overwrites the mapping specified in fields and properties. |
- Organization of this section
-