Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

HibernateTransactionManager.EntityInterceptor Property

Gets or sets a Hibernate entity interceptor that allows to inspect and change property values before writing to and reading from the database. When getting, return the current Hibernate entity interceptor, or

if none.

[Visual Basic]
Public Property EntityInterceptor() As IInterceptor
   Public Get
   End Get
   Public Set
   End Set
End Property
public IInterceptor EntityInterceptor { public get; public set; }

Property Value

The entity interceptor.


Resolves an entity interceptor object name via the object factory, if necessary. Will get applied to any new Session created by this transaction manager. Such an interceptor can either be set at the SessionFactory level, i.e. on LocalSessionFactoryObject, or at the Session level, i.e. on HibernateTemplate, HibernateInterceptor, and HibernateTransactionManager. It's preferable to set it on LocalSessionFactoryObject or HibernateTransactionManager to avoid repeated configuration and guarantee consistent behavior in transactions.


Exception Type Condition
InvalidOperationException If object factory is null and need to get entity interceptor via object name.

See Also

HibernateTransactionManager Class | Spring.Data.NHibernate Namespace