I have a working project with fluent-nhibernate and SQL server 2005.
There are several objects which are all nested / related to eachother. The user is sometimes not sure if he deletes the right object, therefore I would like to inspect the mapping (rather than implementing a special delete scenario) for the object and it's related objects.
My goal is to know which objects the current object has so that I can show the user which will be deleted and which will be kept but only the relation deleted.
Is there any way to access the information I need?
Here is an example what I was looking at:
FluentConfiguration config = Fluently.Configure()
.Database(MsSqlConfiguration.MsSql2005
.ConnectionString(c ...)
.Mappings(m => m.FluentMappings.AddFromAssemblyOf<SomeClass>())
...
In the config-object I cannot see anything useful. There is the config.MappingCfg property but not much more.
Thanks for any help, maybe also a hint how to achieve my goal without fluent-nhibernate itself? (I was also thinking about having an onDelete-event for each class, but that would require twice the "same" work)