hello
Trying to find an example to do "inner/nested-class" (Not inheritance) - I looked at the doc (
http://www.hibernate.org/hib_docs/nhibe ... pping.html ) didn't find an example. Anyone?
I suspect you probably need to do this, am I right?
Code:
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.0">
<class name="nhRegistration.Person, nhRegistration" table="people">
<id name="Id" column="personid" type="Int32">
<generator class="assigned" />
</id>
<property name="Name" column="Name"
type="String(50)"/>
<!-- This is inheritance, not INNER class -->
<subclass name="nhRegistration.Student, nhRegistration"
discriminator-value="student">
<property name="SSN" column="identifier"
type="String"/>
[b]<!-- INNER/nested class here! is this right? -->[/b]
<property name="IPhone" type="Universe.Gadget.iPhone" />
</subclass>
</class>
</hibernate-mapping>
[url]
Example adapted from
http://www.theserverside.net/tt/article ... NHibernate
[/url]
Thanks!