Interface IUnitOfWork<TAccountsRepository, TCharactersRepository, TMonsterTypesRepository, TItemTypesRepository>
Interface for units of work that target the Fibula project.
Inherited Members
System.IDisposable.Dispose()
Namespace: Fibula.Data.Contracts.Abstractions
Assembly: Fibula.Data.Contracts.dll
Syntax
public interface IUnitOfWork<out TAccountsRepository, out TCharactersRepository, out TMonsterTypesRepository, out TItemTypesRepository> : IDisposable where TAccountsRepository : IRepository<IAccountEntity> where TCharactersRepository : IRepository<ICharacterEntity> where TMonsterTypesRepository : IReadOnlyRepository<IMonsterTypeEntity> where TItemTypesRepository : IReadOnlyRepository<IItemTypeEntity>
Type Parameters
Name | Description |
---|---|
TAccountsRepository | The type of accounts repository. |
TCharactersRepository | The type of characters repository. |
TMonsterTypesRepository | The type of monster types repository. |
TItemTypesRepository | The type of item types repository. |
Properties
| Improve this Doc View SourceAccounts
Gets the repository of accounts.
Declaration
TAccountsRepository Accounts { get; }
Property Value
Type | Description |
---|---|
TAccountsRepository |
Characters
Gets the repository of characters.
Declaration
TCharactersRepository Characters { get; }
Property Value
Type | Description |
---|---|
TCharactersRepository |
ItemTypes
Gets the repository of item types.
Declaration
TItemTypesRepository ItemTypes { get; }
Property Value
Type | Description |
---|---|
TItemTypesRepository |
MonsterTypes
Gets the repository of monster types.
Declaration
TMonsterTypesRepository MonsterTypes { get; }
Property Value
Type | Description |
---|---|
TMonsterTypesRepository |
Methods
| Improve this Doc View SourceComplete()
Saves all changes made during this unit of work to the persistent store.
Declaration
int Complete()
Returns
Type | Description |
---|---|
System.Int32 | The number of changes saved. |