Joined: Sun Jun 08, 2008 9:58 pm Posts: 3
|
Version: 1.2.GA
Can I create custom persistent collections for mappings other than bags?
It seems that only bags have the collection-type attribute but I need to create indexed custom collections such as arrays and maps where the index is a column in the database. All the examples I have seen on the net so far use bags. I am I missing something here?
Here is some background on why I want to do this. I need collections which track changes (added and removed items etc) compared to the last persisted state. As nhibernate replaces collection with its own implementation, there seems to be a couple of ways people get arround this. They either create a wrapper arround the nhibernate collection within the class that holds the collection or they create custom persistent collections. I thought the custom collection method seemed a little cleaner so I tried to go down this route but got stuck when I tried to create an array mapping.
|
|