OptimusFramework.DataAccess.Domain
2.0.1
dotnet add package OptimusFramework.DataAccess.Domain --version 2.0.1
NuGet\Install-Package OptimusFramework.DataAccess.Domain -Version 2.0.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="OptimusFramework.DataAccess.Domain" Version="2.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="OptimusFramework.DataAccess.Domain" Version="2.0.1" />
<PackageReference Include="OptimusFramework.DataAccess.Domain" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add OptimusFramework.DataAccess.Domain --version 2.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: OptimusFramework.DataAccess.Domain, 2.0.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package OptimusFramework.DataAccess.Domain@2.0.1
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=OptimusFramework.DataAccess.Domain&version=2.0.1
#tool nuget:?package=OptimusFramework.DataAccess.Domain&version=2.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
OptimusFramework.DataAccess.Domain
Domain layer for data access in the Optimus Framework. Defines repository interfaces, entity contracts, and the Unit of Work pattern for technology-agnostic data persistence.
Features
- Generic Repository Pattern:
IRepository<TEntity, TKey>with full CRUD, filtering, and async support - Unit of Work:
IUnitOfWorkfor transaction management and connection lifecycle - Cache Abstraction:
ICacheProviderfor cache-aside pattern with TTL and pattern matching - Domain Entities:
Company,CompanyType,Image,Metafieldbase entities - Image Management:
IRepoImagewith Base64 conversion, thumbnails, and file system operations - Metafield Support:
IRepoMetafieldfor extensible key-value metadata
Key Interfaces
| Interface | Description |
|---|---|
IRepository<TEntity> |
Generic repository with Add, Update, Where, Count, Any, All, FirstOrDefault |
IRepository<TEntity, TKey> |
Extended with Exists, NoExists, ProcessGetByKey |
IUnitOfWork |
SaveChanges, SaveChangesAsync, ReloadConnectionConfig, BuildNewInstance |
ICacheProvider |
Set, Get, Remove, IsInCache, GetByPattern, GetCachedFunc |
IRepoImage |
Image CRUD with Base64, thumbnail, and format conversion |
IRepoMetafield |
Metafield repository |
Installation
dotnet add package OptimusFramework.DataAccess.Domain
Usage
using OptimusFramework.DataAccess.Domain.Repository;
// Inject repository
public class MyService
{
private readonly IRepository<Product, int> _repo;
public async Task<Product> GetAsync(int id)
{
return await _repo.ProcessGetByKey(id);
}
public async Task<IEnumerable<Product>> FilterAsync()
{
return await _repo.WhereAsync(p => p.Status == StateEnum.Enabled);
}
}
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net10.0
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.3)
- Newtonsoft.Json (>= 13.0.3)
- OptimusFramework.Utils (>= 2.0.1)
- System.Drawing.Common (>= 10.0.0)
NuGet packages (6)
Showing the top 5 NuGet packages that depend on OptimusFramework.DataAccess.Domain:
| Package | Downloads |
|---|---|
|
OptimusFramework.DataAccess.EFCore
Package Description |
|
|
OptimusFramework.DataAccess.Generic
Package Description |
|
|
OptimusFramework.AppService.Generic
Package Description |
|
|
OptimusLog.DataAccess.Domain
Package Description |
|
|
OptimusFramework.DataAccess.Redis
Package Description |
GitHub repositories
This package is not used by any popular GitHub repositories.