@Retention(value=RUNTIME) @Target(value={METHOD,FIELD}) public @interface AuditMappedBy
Annotation to specify a "fake" bi-directional relation. Such a relation uses @OneToMany
+
@JoinColumn
on the one side, and @ManyToOne
+ @Column(insertable=false, updatable=false)
on
the many side. Then, Envers won't use a join table to audit this relation, but will store changes as in a normal
bi-directional relation.
This annotation is experimental and may change in future releases.
Modifier and Type | Required Element and Description |
---|---|
String |
mappedBy |
Modifier and Type | Optional Element and Description |
---|---|
String |
positionMappedBy |
public abstract String mappedBy
@ManyToOne
and @Column(insertable=false, updatable=false)
.public abstract String positionMappedBy
IndexColumn
is used on the collection.
The property should be mapped with @Column(insertable=false, updatable=false)
.Copyright © 2012 JBoss by Red Hat. All Rights Reserved.