NPv.Common.Infrastructure.Domain
1.3.0
dotnet add package NPv.Common.Infrastructure.Domain --version 1.3.0
NuGet\Install-Package NPv.Common.Infrastructure.Domain -Version 1.3.0
<PackageReference Include="NPv.Common.Infrastructure.Domain" Version="1.3.0" />
<PackageVersion Include="NPv.Common.Infrastructure.Domain" Version="1.3.0" />
<PackageReference Include="NPv.Common.Infrastructure.Domain" />
paket add NPv.Common.Infrastructure.Domain --version 1.3.0
#r "nuget: NPv.Common.Infrastructure.Domain, 1.3.0"
#:package NPv.Common.Infrastructure.Domain@1.3.0
#addin nuget:?package=NPv.Common.Infrastructure.Domain&version=1.3.0
#tool nuget:?package=NPv.Common.Infrastructure.Domain&version=1.3.0
NPv.Common.Infrastructure.Domain
A simple and reusable base for domain entities in .NET.
Overview
This library provides a lightweight abstraction for domain entities, including a base Entity
class and IEntity
interface.
It is designed to ensure consistency across domain models and simplify working with repository patterns — especially in EF Core–based infrastructure.
🔧 Ideal for:
- Clean architecture & DDD-based applications
- Shared modeling conventions across services
- Lightweight domain layers without framework coupling
- Subsequently, domain model classes inherit from the entity class to ensure consistency and simplify database operations.
Features
- ✅ Minimalistic Entity and IEntity base types
- 🏷 Optional support for custom attributes like [LongText]
- 🧩 Integrates easily with EF Core and repository layers
Usage
public class Customer : Entity<Guid>
{
public string Name { get; set; } = default!;
}
You can also annotate string properties with [LongText] to mark them for nvarchar(max) mapping in your EF configuration.
[LongText]
public string Description { get; set; } = null!;
Changelog
2025-05-24 Version 1.3
Added [LongText]
attribute
2024-11-18 - Version 1.2.1
- Add correct
README.md
2024-11-13 - Version 1.2.0
- Update to .Net 9
2024-11-12 - Version 1.1.0
- Add README file
- Update to .Net 8
- Refactoring
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. 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. |
-
net9.0
- No dependencies.
NuGet packages (2)
Showing the top 2 NuGet packages that depend on NPv.Common.Infrastructure.Domain:
Package | Downloads |
---|---|
NPv.Common.Infrastructure.Db.Ef
NPv's IGenericRepository realisation for EF including: IDbContextFactory, IDbContextProvider, PerRequestDbContextProvider, ConsoleDbContextProvider |
|
NPv.Common.Infrastructure.Db
NPv's IGenericRepository |
GitHub repositories
This package is not used by any popular GitHub repositories.