mirror of
https://github.com/querydsl/querydsl.git
synced 2026-07-03 21:07:49 +08:00
Add test case
This commit is contained in:
parent
7bf13ccc93
commit
8fd3ba80ff
@ -20,6 +20,10 @@ import com.querydsl.jpa.domain4.BookID;
|
||||
import com.querydsl.jpa.domain4.BookMark;
|
||||
import com.querydsl.jpa.domain4.BookVersion;
|
||||
import com.querydsl.jpa.domain4.Library;
|
||||
import com.querydsl.jpa.domain5.MyEmbeddedAttribute;
|
||||
import com.querydsl.jpa.domain5.MyEntity;
|
||||
import com.querydsl.jpa.domain5.MyMappedSuperclass;
|
||||
import com.querydsl.jpa.domain5.MyOtherEntity;
|
||||
|
||||
public final class Domain {
|
||||
|
||||
@ -84,6 +88,11 @@ public final class Domain {
|
||||
BookID.class,
|
||||
BookMark.class,
|
||||
BookVersion.class,
|
||||
Library.class
|
||||
Library.class,
|
||||
|
||||
MyEmbeddedAttribute.class,
|
||||
MyEntity.class,
|
||||
MyMappedSuperclass.class,
|
||||
MyOtherEntity.class
|
||||
);
|
||||
}
|
||||
|
||||
@ -0,0 +1,9 @@
|
||||
package com.querydsl.jpa.domain5;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
||||
@Embeddable
|
||||
public class MyEmbeddedAttribute {
|
||||
@ManyToOne
|
||||
private MyOtherEntity attributeWithInitProblem;
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
package com.querydsl.jpa.domain5;
|
||||
|
||||
import javax.persistence.Embedded;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.Id;
|
||||
|
||||
import com.querydsl.core.annotations.QueryInit;
|
||||
|
||||
@Entity
|
||||
public class MyEntity extends MyMappedSuperclass {
|
||||
|
||||
@Id
|
||||
private int id;
|
||||
|
||||
@Embedded
|
||||
@QueryInit("*")
|
||||
private MyEmbeddedAttribute embeddedAttribute;
|
||||
}
|
||||
@ -0,0 +1,8 @@
|
||||
package com.querydsl.jpa.domain5;
|
||||
|
||||
import javax.persistence.MappedSuperclass;
|
||||
|
||||
@MappedSuperclass
|
||||
public class MyMappedSuperclass {
|
||||
|
||||
}
|
||||
@ -0,0 +1,11 @@
|
||||
package com.querydsl.jpa.domain5;
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.Id;
|
||||
|
||||
@Entity
|
||||
public class MyOtherEntity {
|
||||
|
||||
@Id
|
||||
private int id;
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user