views:

515

answers:

1

In order to represent inheritance how many hbm files are needed?

How do I represent the relationship between base and subclasses in the subclass hbm file?

I want hbm and pojo class of super and sub class.

+2  A: 

http://www.hibernate.org/hib_docs/v3/reference/en/html/mapping.html#mapping-declaration-subclass

Use the "extends" attribute of the "subclass", "joined-subclass" or "union-subclass" elements. You can put all classes in the same .hbm file or split them into separate files if you wish.

cliff.meyers