I want something like below, Is it possible? Please suggest how can I do this.
Code:
# <class name="Parent">
# <id name="id">
# <generator class="sequence"/>
# </id>
# <property name="name" column="name"/>
# <set name="boyChildren" table="child">
# <composite-key>
# <property column="parent_id"/>
# <property column="gender" value"male"/>
# <composite-key>
# <one-to-many class="Child" column="id"/>
# </set>
# <set name="babyChildren" table="child">
# <composite-key>
# <property column="parent_id"/>
# <property column="gender"/ value="female">
# </composite-key>
# <one-to-many class="Child" column="id"/>
# </set>
# </class>