Diwink.Extensions.EntityFrameworkCore
10.0.1
dotnet add package Diwink.Extensions.EntityFrameworkCore --version 10.0.1
NuGet\Install-Package Diwink.Extensions.EntityFrameworkCore -Version 10.0.1
<PackageReference Include="Diwink.Extensions.EntityFrameworkCore" Version="10.0.1" />
<PackageVersion Include="Diwink.Extensions.EntityFrameworkCore" Version="10.0.1" />
<PackageReference Include="Diwink.Extensions.EntityFrameworkCore" />
paket add Diwink.Extensions.EntityFrameworkCore --version 10.0.1
#r "nuget: Diwink.Extensions.EntityFrameworkCore, 10.0.1"
#:package Diwink.Extensions.EntityFrameworkCore@10.0.1
#addin nuget:?package=Diwink.Extensions.EntityFrameworkCore&version=10.0.1
#tool nuget:?package=Diwink.Extensions.EntityFrameworkCore&version=10.0.1
Digital Wink Entity Framework Extensions
Entity Framework Core Simple Graph Update
It's a simple update method that will help you to do a full update to an aggregate graph with all related entities in it. the update method will take the loaded aggregate entity from the DB and the passed one that may come from the API layer. Internally the method will update just the eager loaded entities in the aggregate "The included entities"
Support (.NET 8-10, EF Core 9-10)
The project now ships net8.0, net9.0, and net10.0 assets, so the package
supports .NET 8.x through .NET 10.x and EF Core 9.x through 10.x while keeping
the same explicit, contract-driven relationship semantics.
Supported Relationship Patterns
| Pattern | Add | Update | Remove | Outcome |
|---|---|---|---|---|
| Pure many-to-many (skip nav) | Link created | Properties updated | Link removed | Related entity preserved |
| Payload many-to-many (join entity) | Association inserted | Payload updated | Association deleted | Related entities preserved |
| Required one-to-one | Dependent inserted | Properties updated | Dependent deleted | Cascade delete |
| Optional one-to-one | Dependent inserted | Properties updated | FK nulled | Dependent preserved |
Rejection Behavior
| Scenario | Exception |
|---|---|
| Unsupported relationship mutated (e.g., one-to-many) | UnsupportedNavigationMutatedException |
| Unloaded navigation with mutations in updated graph | UnloadedNavigationMutationException |
| Mixed supported + unsupported mutations | PartialMutationNotAllowedException |
| Unsupported relationship unchanged | Silently skipped |
Usage
var updated = BuildDesiredState(); // detached graph
var existing = await dbContext.Courses
.Include(c => c.Tags)
.Include(c => c.Policy)
.Include(c => c.MentorAssignments)
.FirstAsync(c => c.Id == id);
dbContext.UpdateGraph(updated, existing);
await dbContext.SaveChangesAsync();
Please don't hesitate to contribute or give us your feedback and/or advice 🌹 🌹
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. 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 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. |
-
net10.0
- Microsoft.EntityFrameworkCore (>= 10.0.5 && < 11.0.0)
-
net8.0
- Microsoft.EntityFrameworkCore (>= 9.0.14 && < 10.0.0)
-
net9.0
- Microsoft.EntityFrameworkCore (>= 9.0.14 && < 10.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.