From: <hib...@li...> - 2006-03-17 09:34:31
|
Author: epbernard Date: 2006-03-17 04:34:28 -0500 (Fri, 17 Mar 2006) New Revision: 9644 Modified: trunk/HibernateExt/metadata/doc/reference/en/modules/entity.xml Log: ANN-245 Modified: trunk/HibernateExt/metadata/doc/reference/en/modules/entity.xml =================================================================== --- trunk/HibernateExt/metadata/doc/reference/en/modules/entity.xml 2006-03-17 08:42:25 UTC (rev 9643) +++ trunk/HibernateExt/metadata/doc/reference/en/modules/entity.xml 2006-03-17 09:34:28 UTC (rev 9644) @@ -1125,11 +1125,18 @@ property using <literal>@MapKey(name="myProperty")</literal> (myProperty is a property name in the target entity). When using <literal>@MapKey</literal> (without property name), the target - entity primary key is used. Be aware that once loaded, the key is no - longer kept in sync with the property, in other words, if you change - the property value, the key will not change automatically in your - Java model (Map support the way Hibernate 3 does is currently not - supported in this release).</para> + entity primary key is used. The map key uses the same column as the + property pointed out: there is no additional column defined to hold + the map key, and it does make sense since the map key actually + represent a target ptoperty. Be aware that once loaded, the key is + no longer kept in sync with the property, in other words, if you + change the property value, the key will not change automatically in + your Java model (Map support the way Hibernate 3 does is currently + not supported in this release). Many people confuse + <literal><map></literal> capabilities and + <literal>@MapKey</literal> ones. These are two different features. + <literal>@MapKey</literal> still has some limitations, please check + the forum or the JIRA tracking system for more informations.</para> <para>Hibernate has several notions of collections.</para> @@ -2190,7 +2197,7 @@ or any secondary table. The <literal>@Tables</literal> annotation allows your to apply indexes on different tables. This annotation is expected where <literal>@javax.persistence.Table</literal> or - <literal>@javax.persistence.SecondaryTable</literal>(s) occurs. </para> + <literal>@javax.persistence.SecondaryTable</literal>(s) occurs.</para> <note> <para><literal>@org.hibernate.annotations.Table</literal> is a @@ -2198,7 +2205,7 @@ <literal>@javax.persistence.Table</literal>. Especially, if you want to change the default name of a table, you must use <literal>@javax.persistence.Table</literal>, not - <literal>@org.hibernate.annotations.Table</literal>. </para> + <literal>@org.hibernate.annotations.Table</literal>.</para> </note> <para><programlisting>@Entity |