Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

HibernateAccessor Members

HibernateAccessor overview

Public Instance Constructors

HibernateAccessor Constructor Initializes a new instance of the HibernateAccessor class.

Public Instance Properties

AdoExceptionTranslator Set the ADO.NET exception translator for this instance. Applied to System.Data.Common.DbException (or provider specific exception type in .NET 1.1) thrown by callback code, be it direct DbException or wrapped Hibernate ADOExceptions. The default exception translator is either a ErrorCodeExceptionTranslator if a DbProvider is available, or a FalbackExceptionTranslator otherwise
AllowCreate Gets or sets if a new Session should be created when no transactional Session can be found for the current thread.
AlwaysUseNewSession Gets or sets a value indicating whether to always use a new Hibernate Session for this template.
CacheQueries Gets or sets a value indicating whether to cache all queries executed by this template.
EntityInterceptor Gets or sets the entity interceptor that allows to inspect and change property values before writing to and reading from the database.
EntityInterceptorObjectName Set the object name of a Hibernate entity interceptor that allows to inspect and change property values before writing to and reading from the database.
ExposeNativeSession Set whether to expose the native Hibernate Session to IHibernateCallback code. Default is "false": a Session proxy will be returned, suppressing
close
calls and automatically applying query cache settings and transaction timeouts.
FetchSize Gets or sets the fetch size for this HibernateTemplate.
MaxResults Gets or sets the maximum number of rows for this HibernateTemplate.
ObjectFactory Set the object factory instance.
QueryCacheRegion Gets or sets the name of the cache region for queries executed by this template.
SessionFactory Gets or sets the session factory that should be used to create NHibernate ISessions.
TemplateFlushMode Gets or sets the template flush mode.

Public Instance Methods

AfterPropertiesSet Ensure SessionFactory is not null
ApplyNamedParameterToQuery Apply the given name parameter to the given Query object.
ConvertHibernateAccessException Convert the given HibernateException to an appropriate exception from the
org.springframework.dao
hierarchy. Will automatically detect wrapped ADO.NET Exceptions and convert them accordingly.
Equals (inherited from Object)Determines whether the specified Object is equal to the current Object.
GetHashCode (inherited from Object)Serves as a hash function for a particular type. GetHashCode is suitable for use in hashing algorithms and data structures like a hash table.
GetType (inherited from Object)Gets the Type of the current instance.
PrepareCriteria Prepare the given Criteria object, applying cache settings and/or a transaction timeout.
PrepareQuery Prepare the given IQuery object, applying cache settings and/or a transaction timeout.
ToString (inherited from Object)Returns a String that represents the current Object.

Protected Instance Properties

Session Gets a Session for use by this template.

Protected Instance Methods

ApplyFlushMode Apply the flush mode that's been specified for this accessor to the given Session.
ConvertAdoAccessExceptionOverloaded. Converts the ADO.NET access exception to an appropriate exception from the
org.springframework.dao
hierarchy. Can be overridden in subclasses.
Finalize (inherited from Object)Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
FlushIfNecessary Flush the given Hibernate Session if necessary.
MemberwiseClone (inherited from Object)Creates a shallow copy of the current Object.

See Also

HibernateAccessor Class | Spring.Data.NHibernate Namespace