diff --git a/.DS_Store b/.DS_Store
new file mode 100644
index 0000000..c02464c
Binary files /dev/null and b/.DS_Store differ
diff --git a/.gitea/workflows/publish-nugets.yaml b/.gitea/workflows/publish-nugets.yaml
new file mode 100644
index 0000000..e69de29
diff --git a/OpenHarbor.CQRS.Abstractions/OpenHarbor.CQRS.Abstractions.csproj b/OpenHarbor.CQRS.Abstractions/OpenHarbor.CQRS.Abstractions.csproj
index 1eb00b8..903f35c 100644
--- a/OpenHarbor.CQRS.Abstractions/OpenHarbor.CQRS.Abstractions.csproj
+++ b/OpenHarbor.CQRS.Abstractions/OpenHarbor.CQRS.Abstractions.csproj
@@ -1,10 +1,22 @@
- netstandard2.1
- https://avatars.githubusercontent.com/u/52874619?v=4
+ net8.0
+ true
David Lebee, Mathias Beaulieu-Duncan
default
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/OpenHarbor.CQRS.Abstractions/ServiceCollectionExtensions.cs b/OpenHarbor.CQRS.Abstractions/ServiceCollectionExtensions.cs
index df2bd5f..efc4fec 100644
--- a/OpenHarbor.CQRS.Abstractions/ServiceCollectionExtensions.cs
+++ b/OpenHarbor.CQRS.Abstractions/ServiceCollectionExtensions.cs
@@ -1,11 +1,12 @@
-using Microsoft.Extensions.DependencyInjection;
+using System.Diagnostics.CodeAnalysis;
+using Microsoft.Extensions.DependencyInjection;
using OpenHarbor.CQRS.Abstractions.Discovery;
namespace OpenHarbor.CQRS.Abstractions;
public static class ServiceCollectionExtensions
{
- public static IServiceCollection AddQuery(this IServiceCollection services)
+ public static IServiceCollection AddQuery(this IServiceCollection services)
where TQuery : class
where TQueryHandler : class, IQueryHandler
{
@@ -19,7 +20,7 @@ public static class ServiceCollectionExtensions
return services;
}
- public static IServiceCollection AddCommand(this IServiceCollection services)
+ public static IServiceCollection AddCommand(this IServiceCollection services)
where TCommand : class
where TCommandHandler : class, ICommandHandler
{
@@ -33,7 +34,7 @@ public static class ServiceCollectionExtensions
return services;
}
- public static IServiceCollection AddCommand(this IServiceCollection services)
+ public static IServiceCollection AddCommand(this IServiceCollection services)
where TCommand : class
where TCommandHandler : class, ICommandHandler
{
diff --git a/OpenHarbor.CQRS.AspNetCore.Abstractions/OpenHarbor.CQRS.AspNetCore.Abstractions.csproj b/OpenHarbor.CQRS.AspNetCore.Abstractions/OpenHarbor.CQRS.AspNetCore.Abstractions.csproj
index dabc93e..72b45cf 100644
--- a/OpenHarbor.CQRS.AspNetCore.Abstractions/OpenHarbor.CQRS.AspNetCore.Abstractions.csproj
+++ b/OpenHarbor.CQRS.AspNetCore.Abstractions/OpenHarbor.CQRS.AspNetCore.Abstractions.csproj
@@ -1,8 +1,20 @@
- netstandard2.1
- https://avatars.githubusercontent.com/u/52874619?v=4
- David Lebee, Mathias Beaulieu-Duncan
+ net8.0
+ true
+ false
default
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/OpenHarbor.CQRS.AspNetCore/Mvc/QueryControllerFeatureProvider.cs b/OpenHarbor.CQRS.AspNetCore/Mvc/QueryControllerFeatureProvider.cs
index de73095..60d7af0 100644
--- a/OpenHarbor.CQRS.AspNetCore/Mvc/QueryControllerFeatureProvider.cs
+++ b/OpenHarbor.CQRS.AspNetCore/Mvc/QueryControllerFeatureProvider.cs
@@ -8,28 +8,22 @@ using OpenHarbor.CQRS.AspNetCore.Abstractions.Attributes;
namespace OpenHarbor.CQRS.AspNetCore.Mvc;
-public class QueryControllerFeatureProvider : IApplicationFeatureProvider
+public class QueryControllerFeatureProvider(ServiceProvider serviceProvider)
+ : IApplicationFeatureProvider
{
- private readonly ServiceProvider _serviceProvider;
-
- public QueryControllerFeatureProvider(ServiceProvider serviceProvider)
+ public void PopulateFeature(IEnumerable parts, ControllerFeature feature)
{
- _serviceProvider = serviceProvider;
- }
-
- public void PopulateFeature(IEnumerable parts, ControllerFeature feature)
- {
- var queryDiscovery = this._serviceProvider.GetRequiredService();
- foreach (var f in queryDiscovery.GetQueries())
+ var queryDiscovery = serviceProvider.GetRequiredService();
+ foreach (var queryMeta in queryDiscovery.GetQueries())
{
- var ignoreAttribute = f.QueryType.GetCustomAttribute();
+ var ignoreAttribute = queryMeta.QueryType.GetCustomAttribute();
if (ignoreAttribute != null)
continue;
- if (f.Category != "BasicQuery")
+ if (queryMeta.Category != "BasicQuery")
continue;
- var controllerType = typeof(QueryController<,>).MakeGenericType(f.QueryType, f.QueryResultType);
+ var controllerType = typeof(QueryController<,>).MakeGenericType(queryMeta.QueryType, queryMeta.QueryResultType);
var controllerTypeInfo = controllerType.GetTypeInfo();
feature.Controllers.Add(controllerTypeInfo);
}
diff --git a/OpenHarbor.CQRS.AspNetCore/OpenHarbor.CQRS.AspNetCore.csproj b/OpenHarbor.CQRS.AspNetCore/OpenHarbor.CQRS.AspNetCore.csproj
index 07fd196..b7d588c 100644
--- a/OpenHarbor.CQRS.AspNetCore/OpenHarbor.CQRS.AspNetCore.csproj
+++ b/OpenHarbor.CQRS.AspNetCore/OpenHarbor.CQRS.AspNetCore.csproj
@@ -2,11 +2,22 @@
net8.0
- https://avatars.githubusercontent.com/u/52874619?v=4
+ false
David Lebee, Mathias Beaulieu-Duncan
- true
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
@@ -16,4 +27,8 @@
+
+
+
+
diff --git a/OpenHarbor.CQRS.DynamicQuery.Abstractions/OpenHarbor.CQRS.DynamicQuery.Abstractions.csproj b/OpenHarbor.CQRS.DynamicQuery.Abstractions/OpenHarbor.CQRS.DynamicQuery.Abstractions.csproj
index bf65d87..f055a35 100644
--- a/OpenHarbor.CQRS.DynamicQuery.Abstractions/OpenHarbor.CQRS.DynamicQuery.Abstractions.csproj
+++ b/OpenHarbor.CQRS.DynamicQuery.Abstractions/OpenHarbor.CQRS.DynamicQuery.Abstractions.csproj
@@ -1,12 +1,23 @@
- netstandard2.1
+ netstandard2.1;net8.0
+ true
enable
- https://avatars.githubusercontent.com/u/52874619?v=4
- David Lebee, Mathias Beaulieu-Duncan
default
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/OpenHarbor.CQRS.DynamicQuery.AspNetCore/OpenHarbor.CQRS.DynamicQuery.AspNetCore.csproj b/OpenHarbor.CQRS.DynamicQuery.AspNetCore/OpenHarbor.CQRS.DynamicQuery.AspNetCore.csproj
index 6b2d249..f1ebc5b 100644
--- a/OpenHarbor.CQRS.DynamicQuery.AspNetCore/OpenHarbor.CQRS.DynamicQuery.AspNetCore.csproj
+++ b/OpenHarbor.CQRS.DynamicQuery.AspNetCore/OpenHarbor.CQRS.DynamicQuery.AspNetCore.csproj
@@ -1,12 +1,21 @@
net8.0
- https://www.gravatar.com/avatar/9cecda5822fc5d4d2e61ec03da571b3d
- David Lebee, Mathias Beaulieu-Duncan
+ false
Open Harbor
- true
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/OpenHarbor.CQRS.DynamicQuery/OpenHarbor.CQRS.DynamicQuery.csproj b/OpenHarbor.CQRS.DynamicQuery/OpenHarbor.CQRS.DynamicQuery.csproj
index 19fe117..c5b47cd 100644
--- a/OpenHarbor.CQRS.DynamicQuery/OpenHarbor.CQRS.DynamicQuery.csproj
+++ b/OpenHarbor.CQRS.DynamicQuery/OpenHarbor.CQRS.DynamicQuery.csproj
@@ -1,11 +1,22 @@
- netstandard2.1
- https://avatars.githubusercontent.com/u/52874619?v=4
- David Lebee, Mathias Beaulieu-Duncan
+ net8.0
+ true
default
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/OpenHarbor.CQRS.DynamicQuery/ServiceCollectionExtensions.cs b/OpenHarbor.CQRS.DynamicQuery/ServiceCollectionExtensions.cs
index f97f2c4..df38e41 100644
--- a/OpenHarbor.CQRS.DynamicQuery/ServiceCollectionExtensions.cs
+++ b/OpenHarbor.CQRS.DynamicQuery/ServiceCollectionExtensions.cs
@@ -1,4 +1,5 @@
-using Microsoft.Extensions.DependencyInjection;
+using System.Diagnostics.CodeAnalysis;
+using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.DependencyInjection.Extensions;
using OpenHarbor.CQRS.Abstractions;
using OpenHarbor.CQRS.Abstractions.Discovery;
@@ -35,7 +36,7 @@ public static class ServiceCollectionExtensions
return services;
}
- public static IServiceCollection AddDynamicQueryWithProvider(this IServiceCollection services, string name = null)
+ public static IServiceCollection AddDynamicQueryWithProvider(this IServiceCollection services, string name = null)
where TQueryableProvider : class, IQueryableProvider
where TSource : class
{
@@ -44,7 +45,7 @@ public static class ServiceCollectionExtensions
return services;
}
- public static IServiceCollection AddDynamicQueryWithParamsAndProvider(this IServiceCollection services, string name = null)
+ public static IServiceCollection AddDynamicQueryWithParamsAndProvider(this IServiceCollection services, string name = null)
where TQueryableProvider : class, IQueryableProvider
where TParams : class
where TSource : class
@@ -84,19 +85,19 @@ public static class ServiceCollectionExtensions
return services;
}
- public static IServiceCollection AddAlterQueryable(this IServiceCollection services)
+ public static IServiceCollection AddAlterQueryable(this IServiceCollection services)
where TService : class, IAlterQueryableService
{
return services.AddTransient, TService>();
}
- public static IServiceCollection AddAlterQueryable(this IServiceCollection services)
+ public static IServiceCollection AddAlterQueryable(this IServiceCollection services)
where TService : class, IAlterQueryableService
{
return services.AddTransient, TService>();
}
- public static IServiceCollection AddAlterQueryableWithParams
+ public static IServiceCollection AddAlterQueryableWithParams
(this IServiceCollection services)
where TParams : class
where TService : class, IAlterQueryableService
@@ -104,7 +105,7 @@ public static class ServiceCollectionExtensions
return services.AddTransient, TService>();
}
- public static IServiceCollection AddAlterQueryableWithParams
+ public static IServiceCollection AddAlterQueryableWithParams
(this IServiceCollection services)
where TParams : class
where TService : class, IAlterQueryableService
@@ -112,7 +113,7 @@ public static class ServiceCollectionExtensions
return services.AddTransient, TService>();
}
- public static IServiceCollection AddDynamicQueryInterceptor(this IServiceCollection services)
+ public static IServiceCollection AddDynamicQueryInterceptor(this IServiceCollection services)
where TInterceptor : class, IQueryInterceptor
{
services.TryAddTransient();
@@ -120,7 +121,7 @@ public static class ServiceCollectionExtensions
new DynamicQueryInterceptorProvider(typeof(TInterceptor)));
}
- public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
+ public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
where T1 : class, IQueryInterceptor
where T2 : class, IQueryInterceptor
{
@@ -130,7 +131,7 @@ public static class ServiceCollectionExtensions
new DynamicQueryInterceptorProvider(typeof(T1), typeof(T2)));
}
- public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
+ public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
where T1 : class, IQueryInterceptor
where T2 : class, IQueryInterceptor
where T3 : class, IQueryInterceptor
@@ -142,7 +143,7 @@ public static class ServiceCollectionExtensions
new DynamicQueryInterceptorProvider(typeof(T1), typeof(T2), typeof(T3)));
}
- public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
+ public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
where T1 : class, IQueryInterceptor
where T2 : class, IQueryInterceptor
where T3 : class, IQueryInterceptor
@@ -156,7 +157,7 @@ public static class ServiceCollectionExtensions
new DynamicQueryInterceptorProvider(typeof(T1), typeof(T2), typeof(T3), typeof(T4)));
}
- public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
+ public static IServiceCollection AddDynamicQueryInterceptors(this IServiceCollection services)
where T1 : class, IQueryInterceptor
where T2 : class, IQueryInterceptor
where T3 : class, IQueryInterceptor
diff --git a/OpenHarbor.CQRS.FluentValidation/OpenHarbor.CQRS.FluentValidation.csproj b/OpenHarbor.CQRS.FluentValidation/OpenHarbor.CQRS.FluentValidation.csproj
index 9109223..8a1a976 100644
--- a/OpenHarbor.CQRS.FluentValidation/OpenHarbor.CQRS.FluentValidation.csproj
+++ b/OpenHarbor.CQRS.FluentValidation/OpenHarbor.CQRS.FluentValidation.csproj
@@ -1,11 +1,22 @@
- netstandard2.1
- https://avatars.githubusercontent.com/u/52874619?v=4
- David Lebee, Mathias Beaulieu-Duncan
+ net8.0
+ true
default
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/OpenHarbor.CQRS.FluentValidation/ServiceCollectionExtensions.cs b/OpenHarbor.CQRS.FluentValidation/ServiceCollectionExtensions.cs
index 2058d59..a2e1d5d 100644
--- a/OpenHarbor.CQRS.FluentValidation/ServiceCollectionExtensions.cs
+++ b/OpenHarbor.CQRS.FluentValidation/ServiceCollectionExtensions.cs
@@ -1,4 +1,5 @@
-using FluentValidation;
+using System.Diagnostics.CodeAnalysis;
+using FluentValidation;
using Microsoft.Extensions.DependencyInjection;
using OpenHarbor.CQRS.Abstractions;
@@ -6,14 +7,14 @@ namespace OpenHarbor.CQRS.FluentValidation;
public static class ServiceCollectionExtensions
{
- private static IServiceCollection AddFluentValidator(this IServiceCollection services)
+ private static IServiceCollection AddFluentValidator(this IServiceCollection services)
where TValidator : class, IValidator
{
services.AddTransient, TValidator>();
return services;
}
- public static IServiceCollection AddCommand(this IServiceCollection services)
+ public static IServiceCollection AddCommand(this IServiceCollection services)
where TCommand : class
where TCommandHandler : class, ICommandHandler
where TValidator : class, IValidator
@@ -22,7 +23,7 @@ public static class ServiceCollectionExtensions
.AddFluentValidator();
}
- public static IServiceCollection AddCommand(this IServiceCollection services)
+ public static IServiceCollection AddCommand(this IServiceCollection services)
where TCommand : class
where TCommandHandler : class, ICommandHandler
where TValidator : class, IValidator
@@ -31,13 +32,14 @@ public static class ServiceCollectionExtensions
.AddFluentValidator();
}
- public static IServiceCollection AddQuery(this IServiceCollection services)
+ public static IServiceCollection AddQuery(this IServiceCollection services)
where TQuery : class
where TQueryHandler : class, IQueryHandler
where TValidator : class, IValidator
{
services.AddQuery()
.AddFluentValidator();
+
return services;
}
}
\ No newline at end of file
diff --git a/OpenHarbor.CQRS/.DS_Store b/OpenHarbor.CQRS/.DS_Store
new file mode 100644
index 0000000..cbb6988
Binary files /dev/null and b/OpenHarbor.CQRS/.DS_Store differ
diff --git a/OpenHarbor.CQRS/OpenHarbor.CQRS.csproj b/OpenHarbor.CQRS/OpenHarbor.CQRS.csproj
index 23fafe9..d464768 100644
--- a/OpenHarbor.CQRS/OpenHarbor.CQRS.csproj
+++ b/OpenHarbor.CQRS/OpenHarbor.CQRS.csproj
@@ -1,11 +1,23 @@
- netstandard2.1
- https://avatars.githubusercontent.com/u/52874619?v=4
+ net8.0
+ true
David Lebee, Mathias Beaulieu-Duncan
default
+ Open Harbor
+ icon.png
+ README.md
+ https://git.openharbor.io/Open-Harbor/dotnet-cqrs
+ git
+ true
+ MIT
+
+
+
+
+
diff --git a/icon.png b/icon.png
new file mode 100644
index 0000000..a8f02f0
Binary files /dev/null and b/icon.png differ