C# Class Arc.Infrastructure.Data.NHibernate.UnitOfWorkFactory

Unit of work factory.
Inheritance: IUnitOfWorkFactory
Show file Open project: marektihkan/Arc

Public Methods

Method Description
Create ( ) : IUnitOfWork

Creates new unit of work or returns existing.

Release ( IUnitOfWork releasable ) : void

Releases the specified unit of work.

UnitOfWorkFactory ( IRegistry registry, ISessionFactory factory ) : Arc.Infrastructure.Registry

Initializes a new instance of the UnitOfWorkFactory class.

Private Methods

Method Description
CreateAndRegisterNewSession ( ) : ISession
CreateAndRegisterNewUnitOfWork ( ) : IUnitOfWork

Method Details

Create() public method

Creates new unit of work or returns existing.
public Create ( ) : IUnitOfWork
return IUnitOfWork

Release() public method

Releases the specified unit of work.
public Release ( IUnitOfWork releasable ) : void
releasable IUnitOfWork The releasable unit of work.
return void

UnitOfWorkFactory() public method

Initializes a new instance of the UnitOfWorkFactory class.
public UnitOfWorkFactory ( IRegistry registry, ISessionFactory factory ) : Arc.Infrastructure.Registry
registry IRegistry The registry.
factory ISessionFactory The NHibernate session factory.
return Arc.Infrastructure.Registry