Hello,
I'm quite new to hibernate so sorry for maybe dump question.
Is it possible to use Hibernate's criteria API on inherited classes? Inheritance strategy is Table per subclass.
To more narrow I need to use Criteria API on non inherited properties.
BaseClass {
baseProp;
}
InhAClass extends BaseClass {
inhAProp;
}
InhBClass extends BaseClass {
inhyBProp;
}
EncapsulClass {
baseClass;
}
Basically what I need to do is polymorfic query on EncapsulClass using Criteria API and as search criterions I have to use properties of extended classes (inhAProp, inhyBProp);
Search result should contain all EncapsulClass-es with InhAClass which satisfies inhAProp criterias and with InhBclass-es which satisfies InhBprop criterias.
If not, do you know some simple workaround?
Thanks a lot
Robert
|