I have a proplem where I have two classes associated with a one to many relation ship. ie one parent has many children.
I have senarios for working with this relationship.
1. where when working with a parent only certain children are loaded, I can acheive this with using a filter is the mapping file and apply the filter when getting the parent.
2. when working with a child in some senarios I do not whant to load the parent, or have it loaded lazily. This proplem occurs if I want to send the object over wcf to a client, serialization invokes the lazy loadable relation. I have not managed to do this yet.
So the question is how do I prevent a many-to-one relationship from loading the parent side of the relationship? Is this possible in NHibernate.
|