mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-06 00:32:18 +00:00
#878 - @AttributeOverride (not wrapped in @AttributeOverrides) is not applied
This commit is contained in:
1 parent
d2b6d06da5
commit
632cf10096
5 files changed
+141
-4
No files matched your search
@@ -0,0 +1,51 @@
|
||||
package com.avaje.tests.model.embedded;
|
||||
|
||||
import javax.persistence.AttributeOverride;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.EmbeddedId;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.Version;
|
||||
|
||||
@Entity
|
||||
public class PrimaryRevision {
|
||||
|
||||
@EmbeddedId
|
||||
// @AttributeOverrides({
|
||||
// @AttributeOverride(name="primaryId", column = @Column(name="id"))
|
||||
// })
|
||||
@AttributeOverride(name="primaryId", column = @Column(name="id"))
|
||||
private RevisionId revisionId;
|
||||
|
||||
String name;
|
||||
|
||||
@Version
|
||||
long version;
|
||||
|
||||
public PrimaryRevision(long someId) {
|
||||
this.revisionId = new RevisionId(someId, 1);
|
||||
}
|
||||
|
||||
public RevisionId getRevisionId() {
|
||||
return revisionId;
|
||||
}
|
||||
|
||||
public void setRevisionId(RevisionId revisionId) {
|
||||
this.revisionId = revisionId;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public long getVersion() {
|
||||
return version;
|
||||
}
|
||||
|
||||
public void setVersion(long version) {
|
||||
this.version = version;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user