My class A look like this:
Code:
public class A {
B myB;
Map myC;
...
}
No other variables are required. B and C are hibernate mapped classes. A doesn't require its own table. What I'm searching for is a mapping for A like this:
Code:
<hibernate-mapping package="client.test">
<class name="A" >
<one-to-one name="myB" class="B"/>
<map name="myC" table="tableC" cascade="all" inverse="true">
<key column="c_id"/>
<index column="date" type="date"/>
<one-to-many class="C"/>
</map>
</class>
</hibernate-mapping>
What I need is an <id> for A. This identifier should be the same as the Identifier of class B. Is there a way to map that id?