1
我有以下情形:休眠@OneToMany内@Embeddable
@Entity
class A {
@ElementCollection
private Set<B> setOfB;
}
@Embeddable
class B{
@OneToMany
private Set<C> setOfC;
}
@Entity
class C{
private String name;
}
继this question看起来这是可行的,但是我收到以下错误。任何想法我做错了什么?
org.hibernate.MappingException: Could not determine type for: java.util.Set, at table: A_setOfB, for columns: [org.hibernate.mapping.Column(setOfB.setOfC)]
谢谢。