Hi, I am working on my 1st project using hibernatea and I am stuck with this problem. Can any one please tell me what is the way to map an array of objects inside a map? Problem is <array> is not shown inside the <map> tag. Any reason for this?
Class to be mapped is
Class Policy{ private Map<String, Executor> executors = new HashMap<String, Executor> } where Class Executor{ private String name; private Money[] amountList; }
<class name="Policy" table="POLICY"> <id> ... </id> <map name="executors" table="EXECUTORS" cascade="all"> <key ... /> <index column="ID" type="string"/> <composite-element class="Executor"> <property name="name" column="NAME"/> but how to map array of objects amountList now? </composite-element> </map> </class>
All suggestions are welcome. Thanks.
|