design patterns - Get list of changed fields in Entity from NHibernate Session -


I want to track changes to my domain model. I know that the NHibernate ISession unit is an implementation of the official format, Tracks these changes, for example, what is a way to remove them before committing () or flush ()?

Take a look at NHibernate's IInterceptor.

OnFlushDirty - will show you the properties to continue on an updated object.

You just need to create an interceptor class that implements this interface, and when you use your NHibernate session If you configure, then tell that to use that class.


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -