AdaskoTheBeAsT.FluentValidation.SimpleInjector
11.0.0
dotnet add package AdaskoTheBeAsT.FluentValidation.SimpleInjector --version 11.0.0
NuGet\Install-Package AdaskoTheBeAsT.FluentValidation.SimpleInjector -Version 11.0.0
<PackageReference Include="AdaskoTheBeAsT.FluentValidation.SimpleInjector" Version="11.0.0" />
<PackageVersion Include="AdaskoTheBeAsT.FluentValidation.SimpleInjector" Version="11.0.0" />
<PackageReference Include="AdaskoTheBeAsT.FluentValidation.SimpleInjector" />
paket add AdaskoTheBeAsT.FluentValidation.SimpleInjector --version 11.0.0
#r "nuget: AdaskoTheBeAsT.FluentValidation.SimpleInjector, 11.0.0"
#:package AdaskoTheBeAsT.FluentValidation.SimpleInjector@11.0.0
#addin nuget:?package=AdaskoTheBeAsT.FluentValidation.SimpleInjector&version=11.0.0
#tool nuget:?package=AdaskoTheBeAsT.FluentValidation.SimpleInjector&version=11.0.0
AdaskoTheBeAsT.FluentValidation.SimpleInjector
FluentValidation extensions to SimpleInjector
Badges
Usage
This library scans assemblies and adds implementations of IValidator<> to the SimpleInjector container.
There are few options to use with Container instance:
Marker type from assembly which will be scanned
container.AddFluentValidation(typeof(MyValidator), type2 /*, ...*/);List of assemblies which will be scanned.
Below is sample for scanning assemblies from some solution.
[ExcludeFromCodeCoverage] public static class FluentValidationConfigurator { private const string NamespacePrefix = "YourNamespace"; public static void Configure(Container container) { var loadedAssemblies = AppDomain.CurrentDomain.GetAssemblies().ToList(); var assemblies = new List<Assembly>(); var mainAssembly = typeof(FluentValidationConfigurator).Assembly; var refAssemblies = mainAssembly.GetReferencedAssemblies(); foreach (var assemblyName in refAssemblies .Where(a => a.FullName.StartsWith(NamespacePrefix, StringComparison.OrdinalIgnoreCase))) { var assembly = loadedAssemblies.Find(l => l.FullName == assemblyName.FullName) ?? AppDomain.CurrentDomain.Load(assemblyName); assemblies.Add(assembly); } container.AddFluentValidation(assemblies); } }Special configuration action with different lifetime for validators
container.AddFluentValidation( cfg => { cfg.WithAssembliesToScan(assemblies); cfg.AsScoped(); });
| 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
- FluentValidation (>= 12.1.0)
- SimpleInjector (>= 5.5.0)
-
net8.0
- FluentValidation (>= 12.1.0)
- SimpleInjector (>= 5.5.0)
-
net9.0
- FluentValidation (>= 12.1.0)
- SimpleInjector (>= 5.5.0)
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 |
|---|---|---|
| 11.0.0 | 378 | 11/12/2025 |
| 10.0.0 | 469 | 1/4/2025 |
| 9.2.0 | 391 | 8/18/2024 |
| 9.0.2 | 268 | 5/27/2024 |
| 9.0.1 | 327 | 1/27/2024 |
| 9.0.0 | 346 | 12/2/2023 |
| 8.2.0 | 351 | 7/16/2023 |
| 8.1.0 | 297 | 5/4/2023 |
| 7.1.0 | 474 | 1/22/2023 |
| 7.0.0 | 557 | 11/13/2022 |
| 6.3.2 | 564 | 10/17/2022 |
| 6.3.1 | 659 | 9/25/2022 |
| 6.3.0 | 640 | 9/7/2022 |
| 6.2.0 | 647 | 7/24/2022 |
| 6.1.0 | 648 | 7/5/2022 |
| 6.0.0 | 627 | 5/14/2022 |
| 5.3.4 | 753 | 2/9/2022 |
| 5.3.3 | 489 | 1/2/2022 |
| 5.3.2 | 593 | 10/30/2021 |
| 5.3.1 | 717 | 8/29/2021 |
- update .NET 10.0
- update FluentValidation 12.1.0
- update SimpleInjector 5.5.0