M3diator.DependencyInjection
1.0.0
dotnet add package M3diator.DependencyInjection --version 1.0.0
NuGet\Install-Package M3diator.DependencyInjection -Version 1.0.0
<PackageReference Include="M3diator.DependencyInjection" Version="1.0.0" />
<PackageVersion Include="M3diator.DependencyInjection" Version="1.0.0" />
<PackageReference Include="M3diator.DependencyInjection" />
paket add M3diator.DependencyInjection --version 1.0.0
#r "nuget: M3diator.DependencyInjection, 1.0.0"
#:package M3diator.DependencyInjection@1.0.0
#addin nuget:?package=M3diator.DependencyInjection&version=1.0.0
#tool nuget:?package=M3diator.DependencyInjection&version=1.0.0
M3diator
M3diator is a custom implementation of the Mediator pattern for .NET applications. It draws inspiration from the popular MediatR library's API structure, providing a familiar way to decouple in-process messaging (commands, queries, notifications) without depending on the MediatR NuGet package itself.
The primary goal is to offer similar concepts like requests, handlers, notifications, and pipeline behaviors for managing cross-cutting concerns, allowing developers who are familiar with MediatR's approach to use a custom, dependency-free alternative.
Features
- Request/Response (Command/Query) Messaging: Send requests and receive responses via
IMediator.Send
. - Notification Broadcasting: Publish notifications to multiple handlers via
IMediator.Publish
. - Pipeline Behaviors: Intercept requests and notifications to add cross-cutting concerns like logging, validation, caching, transactions, etc., using
IPipelineBehavior
. - Dependency Injection Friendly: Easily register handlers and the mediator itself using the provided
M3diator.DependencyInjection
package (AddM3diator
extension method).
Installation
Install the necessary packages using the .NET CLI:
# Core M3diator library (interfaces and implementation)
dotnet add package M3diator
# Dependency Injection extensions for easy setup
dotnet add package M3diator.DependencyInjection
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
- M3diator (>= 1.0.0)
- Microsoft.Extensions.DependencyInjection (>= 9.0.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last Updated |
---|