mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-10 13:14:50 +00:00
HHH-4362 - @RowId
This commit is contained in:
parent
df9d8939bb
commit
ada64c172a
@ -53,4 +53,5 @@
|
||||
String persister() default "";
|
||||
/** optimistic locking strategy */
|
||||
OptimisticLockType optimisticLock() default OptimisticLockType.VERSION;
|
||||
String rowId() default "";
|
||||
}
|
||||
|
@ -123,6 +123,7 @@ public class EntityBinder {
|
||||
private AccessType propertyAccessType = AccessType.DEFAULT;
|
||||
private boolean wrapIdsInEmbeddedComponents;
|
||||
private String subselect;
|
||||
private String rowId;
|
||||
|
||||
|
||||
public boolean wrapIdsInEmbeddedComponents() {
|
||||
@ -155,6 +156,7 @@ private void bindHibernateAnnotation(org.hibernate.annotations.Entity hibAnn) {
|
||||
optimisticLockType = hibAnn.optimisticLock();
|
||||
selectBeforeUpdate = hibAnn.selectBeforeUpdate();
|
||||
polymorphismType = hibAnn.polymorphism();
|
||||
rowId = hibAnn.rowId();
|
||||
explicitHibernateEntityAnnotation = true;
|
||||
//persister handled in bind
|
||||
}
|
||||
@ -165,6 +167,7 @@ private void bindHibernateAnnotation(org.hibernate.annotations.Entity hibAnn) {
|
||||
optimisticLockType = OptimisticLockType.VERSION;
|
||||
polymorphismType = PolymorphismType.IMPLICIT;
|
||||
selectBeforeUpdate = false;
|
||||
rowId = "";
|
||||
}
|
||||
}
|
||||
|
||||
@ -504,6 +507,7 @@ public void bindTable(
|
||||
mappings,
|
||||
this.subselect
|
||||
);
|
||||
table.setRowId( rowId );
|
||||
|
||||
if ( persistentClass instanceof TableOwner ) {
|
||||
LOG.bindEntityOnTable(persistentClass.getEntityName(), table.getName());
|
||||
|
Loading…
x
Reference in New Issue
Block a user