From cbf135b6e8c11d56b18bbde06a8e92f1704a6c97 Mon Sep 17 00:00:00 2001 From: Kevin J Lambert Date: Thu, 27 Jun 2024 13:54:23 -0400 Subject: [PATCH] identifiers don't need to be structs --- .../Handlers/CreationHandler.cs | 9 ++------- .../Handlers/PhysicalDeletionHandler.cs | 7 ++----- .../Handlers/RetrievalHandler.cs | 2 +- .../Handlers/RevisionHandler.cs | 9 ++------- .../YuckQi.Data.DocumentDb.DynamoDb.csproj | 2 +- .../Extensions/DocumentModelExtensions.cs | 4 ++-- .../Handlers/CreationHandler.cs | 8 ++++---- .../Handlers/PhysicalDeletionHandler.cs | 8 ++++---- .../Handlers/RetrievalHandler.cs | 4 ++-- .../Handlers/RevisionHandler.cs | 12 ++++++------ .../YuckQi.Data.DocumentDb.MongoDb.csproj | 2 +- src/YuckQi.Data.MemDb/YuckQi.Data.MemDb.csproj | 2 +- .../Handlers/RetrievalHandler.cs | 4 ++-- .../Handlers/SearchHandler.cs | 4 ++-- .../YuckQi.Data.Sql.Dapper.MySql.csproj | 2 +- .../Handlers/RetrievalHandler.cs | 4 ++-- .../Handlers/SearchHandler.cs | 4 ++-- .../YuckQi.Data.Sql.Dapper.Oracle.csproj | 2 +- .../Handlers/RetrievalHandler.cs | 4 ++-- .../Handlers/SearchHandler.cs | 4 ++-- .../YuckQi.Data.Sql.Dapper.SqlServer.csproj | 2 +- .../YuckQi.Data.Sql.Dapper.csproj | 2 +- .../YuckQi.Data.Sql.EntityFramework.csproj | 2 +- src/YuckQi.Data/YuckQi.Data.csproj | 2 +- 24 files changed, 46 insertions(+), 59 deletions(-) diff --git a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/CreationHandler.cs b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/CreationHandler.cs index 98fcbbd..d1d6fd1 100644 --- a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/CreationHandler.cs +++ b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/CreationHandler.cs @@ -1,9 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using Amazon.DynamoDBv2.DataModel; +using Amazon.DynamoDBv2.DataModel; using CSharpFunctionalExtensions; using YuckQi.Data.Handlers.Abstract; using YuckQi.Data.Handlers.Options; @@ -13,7 +8,7 @@ namespace YuckQi.Data.DocumentDb.DynamoDb.Handlers; -public class CreationHandler : CreationHandler where TEntity : IEntity, ICreated where TIdentifier : struct, IEquatable where TScope : IDynamoDBContext? +public class CreationHandler : CreationHandler where TEntity : IEntity, ICreated where TIdentifier : IEquatable where TScope : IDynamoDBContext? { public CreationHandler() : this(null) { } diff --git a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/PhysicalDeletionHandler.cs b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/PhysicalDeletionHandler.cs index 63f0130..fc1959c 100644 --- a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/PhysicalDeletionHandler.cs +++ b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/PhysicalDeletionHandler.cs @@ -1,14 +1,11 @@ -using System; -using System.Threading; -using System.Threading.Tasks; -using Amazon.DynamoDBv2.DataModel; +using Amazon.DynamoDBv2.DataModel; using YuckQi.Data.Handlers.Abstract; using YuckQi.Domain.Entities.Abstract; using YuckQi.Extensions.Mapping.Abstractions; namespace YuckQi.Data.DocumentDb.DynamoDb.Handlers; -public class PhysicalDeletionHandler : PhysicalDeletionHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDynamoDBContext? +public class PhysicalDeletionHandler : PhysicalDeletionHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDynamoDBContext? { public PhysicalDeletionHandler() : base(null) { } } diff --git a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RetrievalHandler.cs b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RetrievalHandler.cs index 10f77c4..dfabbb5 100644 --- a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RetrievalHandler.cs +++ b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RetrievalHandler.cs @@ -8,7 +8,7 @@ namespace YuckQi.Data.DocumentDb.DynamoDb.Handlers; -public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDynamoDBContext? +public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDynamoDBContext? { public RetrievalHandler(Func hashKeyValueFactory) : base(hashKeyValueFactory, null) { } diff --git a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RevisionHandler.cs b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RevisionHandler.cs index 809979e..52e7dc9 100644 --- a/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RevisionHandler.cs +++ b/src/YuckQi.Data.DocumentDb.DynamoDb/Handlers/RevisionHandler.cs @@ -1,9 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using Amazon.DynamoDBv2.DataModel; +using Amazon.DynamoDBv2.DataModel; using YuckQi.Data.Handlers.Abstract; using YuckQi.Data.Handlers.Options; using YuckQi.Domain.Aspects.Abstract; @@ -12,7 +7,7 @@ namespace YuckQi.Data.DocumentDb.DynamoDb.Handlers; -public class RevisionHandler : RevisionHandler where TEntity : IEntity, IRevised where TIdentifier : struct, IEquatable where TScope : IDynamoDBContext? +public class RevisionHandler : RevisionHandler where TEntity : IEntity, IRevised where TIdentifier : IEquatable where TScope : IDynamoDBContext? { public RevisionHandler() : this(null) { } diff --git a/src/YuckQi.Data.DocumentDb.DynamoDb/YuckQi.Data.DocumentDb.DynamoDb.csproj b/src/YuckQi.Data.DocumentDb.DynamoDb/YuckQi.Data.DocumentDb.DynamoDb.csproj index f2ed556..49a3027 100644 --- a/src/YuckQi.Data.DocumentDb.DynamoDb/YuckQi.Data.DocumentDb.DynamoDb.csproj +++ b/src/YuckQi.Data.DocumentDb.DynamoDb/YuckQi.Data.DocumentDb.DynamoDb.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for Amazon DynamoDB databases. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.DocumentDb.MongoDb/Extensions/DocumentModelExtensions.cs b/src/YuckQi.Data.DocumentDb.MongoDb/Extensions/DocumentModelExtensions.cs index ed6b3a4..8b59f86 100644 --- a/src/YuckQi.Data.DocumentDb.MongoDb/Extensions/DocumentModelExtensions.cs +++ b/src/YuckQi.Data.DocumentDb.MongoDb/Extensions/DocumentModelExtensions.cs @@ -18,7 +18,7 @@ public static class DocumentModelExtensions public static String? GetDatabaseName(this Type? type) => type != null ? DatabaseNameByType.GetOrAdd(type, identifier => GetDatabaseAttribute(identifier).Name) : null; - public static TIdentifier GetIdentifier(this TDocument document) where TIdentifier : struct + public static TIdentifier? GetIdentifier(this TDocument document) { if (document == null) return default; @@ -31,7 +31,7 @@ public static TIdentifier GetIdentifier(this TDocument d return default; } - public static StringFieldDefinition? GetIdentifierFieldDefinition(this Type? type) where TIdentifier : struct + public static StringFieldDefinition? GetIdentifierFieldDefinition(this Type? type) { if (type == null) return null; diff --git a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/CreationHandler.cs b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/CreationHandler.cs index ee12774..8ac9097 100644 --- a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/CreationHandler.cs +++ b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/CreationHandler.cs @@ -9,14 +9,14 @@ namespace YuckQi.Data.DocumentDb.MongoDb.Handlers; -public class CreationHandler : CreationHandler where TEntity : IEntity, ICreated where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class CreationHandler : CreationHandler where TEntity : IEntity, ICreated where TIdentifier : IEquatable where TScope : IClientSessionHandle? { public CreationHandler() : this(null) { } public CreationHandler(CreationOptions? options) : base(options, null) { } } -public class CreationHandler : CreationHandlerBase where TEntity : IEntity, ICreated where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class CreationHandler : CreationHandlerBase where TEntity : IEntity, ICreated where TIdentifier : IEquatable where TScope : IClientSessionHandle? { private static readonly Type DocumentType = typeof(TDocument); @@ -54,7 +54,7 @@ public override async Task> Create(IEnumerable ent return list; } - protected override Maybe DoCreate(TEntity entity, TScope? scope) + protected override Maybe DoCreate(TEntity entity, TScope? scope) { if (scope == null) throw new ArgumentNullException(nameof(scope)); @@ -68,7 +68,7 @@ protected override Maybe DoCreate(TEntity entity, TScope? scope) return document.GetIdentifier(); } - protected override async Task> DoCreate(TEntity entity, TScope? scope, CancellationToken cancellationToken) + protected override async Task> DoCreate(TEntity entity, TScope? scope, CancellationToken cancellationToken) { if (scope == null) throw new ArgumentNullException(nameof(scope)); diff --git a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/PhysicalDeletionHandler.cs b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/PhysicalDeletionHandler.cs index 47beb0a..51e2b9d 100644 --- a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/PhysicalDeletionHandler.cs +++ b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/PhysicalDeletionHandler.cs @@ -6,12 +6,12 @@ namespace YuckQi.Data.DocumentDb.MongoDb.Handlers; -public class PhysicalDeletionHandler : PhysicalDeletionHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class PhysicalDeletionHandler : PhysicalDeletionHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IClientSessionHandle? { public PhysicalDeletionHandler() : base(null) { } } -public class PhysicalDeletionHandler : PhysicalDeletionHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class PhysicalDeletionHandler : PhysicalDeletionHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IClientSessionHandle? { private static readonly Type DocumentType = typeof(TDocument); @@ -26,7 +26,7 @@ protected override Boolean DoDelete(TEntity entity, TScope? scope) var collection = database.GetCollection(DocumentType.GetCollectionName()); var document = GetDocument(entity); var field = DocumentType.GetIdentifierFieldDefinition(); - var identifier = document?.GetIdentifier(); + var identifier = document != null ? document.GetIdentifier() : default; var filter = Builders.Filter.Eq(field, identifier); var result = collection.DeleteOne(scope, filter); @@ -42,7 +42,7 @@ protected override async Task DoDelete(TEntity entity, TScope? scope, C var collection = database.GetCollection(DocumentType.GetCollectionName()); var document = GetDocument(entity); var field = DocumentType.GetIdentifierFieldDefinition(); - var identifier = document?.GetIdentifier(); + var identifier = document != null ? document.GetIdentifier() : default; var filter = Builders.Filter.Eq(field, identifier); var result = await collection.DeleteOneAsync(scope, filter, cancellationToken: cancellationToken); diff --git a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RetrievalHandler.cs b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RetrievalHandler.cs index 1e78280..e960b17 100644 --- a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RetrievalHandler.cs +++ b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RetrievalHandler.cs @@ -7,12 +7,12 @@ namespace YuckQi.Data.DocumentDb.MongoDb.Handlers; -public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IClientSessionHandle? { public RetrievalHandler() : base(null) { } } -public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IClientSessionHandle? { private static readonly Type DocumentType = typeof(TDocument); diff --git a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RevisionHandler.cs b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RevisionHandler.cs index 2fab1b7..cff9828 100644 --- a/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RevisionHandler.cs +++ b/src/YuckQi.Data.DocumentDb.MongoDb/Handlers/RevisionHandler.cs @@ -8,14 +8,14 @@ namespace YuckQi.Data.DocumentDb.MongoDb.Handlers; -public class RevisionHandler : RevisionHandler where TEntity : IEntity, IRevised where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class RevisionHandler : RevisionHandler where TEntity : IEntity, IRevised where TIdentifier : IEquatable where TScope : IClientSessionHandle? { public RevisionHandler() : this(null) { } public RevisionHandler(RevisionOptions? options) : base(options, null) { } } -public class RevisionHandler : RevisionHandlerBase where TEntity : IEntity, IRevised where TIdentifier : struct, IEquatable where TScope : IClientSessionHandle? +public class RevisionHandler : RevisionHandlerBase where TEntity : IEntity, IRevised where TIdentifier : IEquatable where TScope : IClientSessionHandle? { private static readonly Type DocumentType = typeof(TDocument); @@ -36,7 +36,7 @@ public override IEnumerable Revise(IEnumerable entities, TScop foreach (var document in documents) { - var identifier = document?.GetIdentifier(); + var identifier = document != null ? document.GetIdentifier() : default; var filter = Builders.Filter.Eq(field, identifier); collection.ReplaceOne(scope, filter, document); @@ -58,7 +58,7 @@ public override async Task> Revise(IEnumerable ent foreach (var document in documents) { - var identifier = document?.GetIdentifier(); + var identifier = document != null ? document.GetIdentifier() : default; var filter = Builders.Filter.Eq(field, identifier); await collection.ReplaceOneAsync(scope, filter, document, cancellationToken: cancellationToken); @@ -76,7 +76,7 @@ protected override Boolean DoRevise(TEntity entity, TScope? scope) var collection = database.GetCollection(DocumentType.GetCollectionName()); var field = DocumentType.GetIdentifierFieldDefinition(); var document = MapToData(entity); - var identifier = document?.GetIdentifier(); + var identifier = document != null ? document.GetIdentifier() : default; var filter = Builders.Filter.Eq(field, identifier); if (document == null) throw new NullReferenceException(); @@ -95,7 +95,7 @@ protected override async Task DoRevise(TEntity entity, TScope? scope, C var collection = database.GetCollection(DocumentType.GetCollectionName()); var field = DocumentType.GetIdentifierFieldDefinition(); var document = MapToData(entity); - var identifier = document?.GetIdentifier(); + var identifier = document != null ? document.GetIdentifier() : default; var filter = Builders.Filter.Eq(field, identifier); if (document == null) throw new NullReferenceException(); diff --git a/src/YuckQi.Data.DocumentDb.MongoDb/YuckQi.Data.DocumentDb.MongoDb.csproj b/src/YuckQi.Data.DocumentDb.MongoDb/YuckQi.Data.DocumentDb.MongoDb.csproj index a1ab150..e8f7282 100644 --- a/src/YuckQi.Data.DocumentDb.MongoDb/YuckQi.Data.DocumentDb.MongoDb.csproj +++ b/src/YuckQi.Data.DocumentDb.MongoDb/YuckQi.Data.DocumentDb.MongoDb.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for MongoDB databases. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.MemDb/YuckQi.Data.MemDb.csproj b/src/YuckQi.Data.MemDb/YuckQi.Data.MemDb.csproj index ded3c1e..46e031c 100644 --- a/src/YuckQi.Data.MemDb/YuckQi.Data.MemDb.csproj +++ b/src/YuckQi.Data.MemDb/YuckQi.Data.MemDb.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for a in-memory "database" (ConcurrentDictionary), ideal for rapid development without external dependencies. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/RetrievalHandler.cs b/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/RetrievalHandler.cs index e3e37cc..8d5b795 100644 --- a/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/RetrievalHandler.cs +++ b/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/RetrievalHandler.cs @@ -7,7 +7,7 @@ namespace YuckQi.Data.Sql.Dapper.MySql.Handlers; -public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public RetrievalHandler() : this(new SqlGenerator()) { } @@ -16,7 +16,7 @@ public RetrievalHandler(ISqlGenerator sqlGenerator) : this(sqlGenerator, DbTypeM public RetrievalHandler(ISqlGenerator sqlGenerator, IReadOnlyDictionary dbTypeMap) : base(sqlGenerator, dbTypeMap, null) { } } -public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public RetrievalHandler(IMapper mapper) : this(new SqlGenerator(), mapper) { } diff --git a/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/SearchHandler.cs b/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/SearchHandler.cs index c4283ae..e24ae8b 100644 --- a/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/SearchHandler.cs +++ b/src/YuckQi.Data.Sql.Dapper.MySql/Handlers/SearchHandler.cs @@ -7,7 +7,7 @@ namespace YuckQi.Data.Sql.Dapper.MySql.Handlers; -public class SearchHandler : SearchHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class SearchHandler : SearchHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public SearchHandler() : this(new SqlGenerator()) { } @@ -16,7 +16,7 @@ public SearchHandler(ISqlGenerator sqlGenerator) : this(sqlGenerator, DbTypeMap. public SearchHandler(ISqlGenerator sqlGenerator, IReadOnlyDictionary dbTypeMap) : base(sqlGenerator, dbTypeMap, null) { } } -public class SearchHandler : SearchHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class SearchHandler : SearchHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public SearchHandler(IMapper mapper) : this(new SqlGenerator(), mapper) { } diff --git a/src/YuckQi.Data.Sql.Dapper.MySql/YuckQi.Data.Sql.Dapper.MySql.csproj b/src/YuckQi.Data.Sql.Dapper.MySql/YuckQi.Data.Sql.Dapper.MySql.csproj index f85e33d..72fd5b1 100644 --- a/src/YuckQi.Data.Sql.Dapper.MySql/YuckQi.Data.Sql.Dapper.MySql.csproj +++ b/src/YuckQi.Data.Sql.Dapper.MySql/YuckQi.Data.Sql.Dapper.MySql.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for MySQL databases using Dapper and SimpleCRUD. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/RetrievalHandler.cs b/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/RetrievalHandler.cs index 9bc3c4e..e687d63 100644 --- a/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/RetrievalHandler.cs +++ b/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/RetrievalHandler.cs @@ -7,7 +7,7 @@ namespace YuckQi.Data.Sql.Dapper.Oracle.Handlers; -public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public RetrievalHandler() : this(new SqlGenerator()) { } @@ -16,7 +16,7 @@ public RetrievalHandler(ISqlGenerator sqlGenerator) : this(sqlGenerator, DbTypeM public RetrievalHandler(ISqlGenerator sqlGenerator, IReadOnlyDictionary dbTypeMap) : base(sqlGenerator, dbTypeMap, null) { } } -public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public RetrievalHandler(IMapper mapper) : this(new SqlGenerator(), mapper) { } diff --git a/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/SearchHandler.cs b/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/SearchHandler.cs index 6069e50..787f2f7 100644 --- a/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/SearchHandler.cs +++ b/src/YuckQi.Data.Sql.Dapper.Oracle/Handlers/SearchHandler.cs @@ -7,7 +7,7 @@ namespace YuckQi.Data.Sql.Dapper.Oracle.Handlers; -public class SearchHandler : SearchHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class SearchHandler : SearchHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public SearchHandler() : this(new SqlGenerator()) { } @@ -16,7 +16,7 @@ public SearchHandler(ISqlGenerator sqlGenerator) : this(sqlGenerator, DbTypeMap. public SearchHandler(ISqlGenerator sqlGenerator, IReadOnlyDictionary dbTypeMap) : base(sqlGenerator, dbTypeMap, null) { } } -public class SearchHandler : SearchHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class SearchHandler : SearchHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public SearchHandler(IMapper mapper) : this(new SqlGenerator(), mapper) { } diff --git a/src/YuckQi.Data.Sql.Dapper.Oracle/YuckQi.Data.Sql.Dapper.Oracle.csproj b/src/YuckQi.Data.Sql.Dapper.Oracle/YuckQi.Data.Sql.Dapper.Oracle.csproj index 18e1039..88de840 100644 --- a/src/YuckQi.Data.Sql.Dapper.Oracle/YuckQi.Data.Sql.Dapper.Oracle.csproj +++ b/src/YuckQi.Data.Sql.Dapper.Oracle/YuckQi.Data.Sql.Dapper.Oracle.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for Oracle databases using Dapper and SimpleCRUD. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/RetrievalHandler.cs b/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/RetrievalHandler.cs index 28abe07..b2d43dd 100644 --- a/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/RetrievalHandler.cs +++ b/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/RetrievalHandler.cs @@ -7,7 +7,7 @@ namespace YuckQi.Data.Sql.Dapper.SqlServer.Handlers; -public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class RetrievalHandler : RetrievalHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public RetrievalHandler() : this(new SqlGenerator()) { } @@ -16,7 +16,7 @@ public RetrievalHandler(ISqlGenerator sqlGenerator) : this(sqlGenerator, DbTypeM public RetrievalHandler(ISqlGenerator sqlGenerator, IReadOnlyDictionary dbTypeMap) : base(sqlGenerator, dbTypeMap, null) { } } -public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class RetrievalHandler : RetrievalHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public RetrievalHandler(IMapper mapper) : this(new SqlGenerator(), mapper) { } diff --git a/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/SearchHandler.cs b/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/SearchHandler.cs index 46289a8..41a9dee 100644 --- a/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/SearchHandler.cs +++ b/src/YuckQi.Data.Sql.Dapper.SqlServer/Handlers/SearchHandler.cs @@ -7,7 +7,7 @@ namespace YuckQi.Data.Sql.Dapper.SqlServer.Handlers; -public class SearchHandler : SearchHandler where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class SearchHandler : SearchHandler where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public SearchHandler() : this(new SqlGenerator()) { } @@ -16,7 +16,7 @@ public SearchHandler(ISqlGenerator sqlGenerator) : this(sqlGenerator, DbTypeMap. public SearchHandler(ISqlGenerator sqlGenerator, IReadOnlyDictionary dbTypeMap) : base(sqlGenerator, dbTypeMap, null) { } } -public class SearchHandler : SearchHandlerBase where TEntity : IEntity where TIdentifier : struct, IEquatable where TScope : IDbTransaction? +public class SearchHandler : SearchHandlerBase where TEntity : IEntity where TIdentifier : IEquatable where TScope : IDbTransaction? { public SearchHandler(IMapper mapper) : this(new SqlGenerator(), mapper) { } diff --git a/src/YuckQi.Data.Sql.Dapper.SqlServer/YuckQi.Data.Sql.Dapper.SqlServer.csproj b/src/YuckQi.Data.Sql.Dapper.SqlServer/YuckQi.Data.Sql.Dapper.SqlServer.csproj index d6f767a..df4a417 100644 --- a/src/YuckQi.Data.Sql.Dapper.SqlServer/YuckQi.Data.Sql.Dapper.SqlServer.csproj +++ b/src/YuckQi.Data.Sql.Dapper.SqlServer/YuckQi.Data.Sql.Dapper.SqlServer.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for MSSQL databases using Dapper and SimpleCRUD. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.Sql.Dapper/YuckQi.Data.Sql.Dapper.csproj b/src/YuckQi.Data.Sql.Dapper/YuckQi.Data.Sql.Dapper.csproj index f6cd0e7..21f10ca 100644 --- a/src/YuckQi.Data.Sql.Dapper/YuckQi.Data.Sql.Dapper.csproj +++ b/src/YuckQi.Data.Sql.Dapper/YuckQi.Data.Sql.Dapper.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for SQL databases using Dapper and SimpleCRUD. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data.Sql.EntityFramework/YuckQi.Data.Sql.EntityFramework.csproj b/src/YuckQi.Data.Sql.EntityFramework/YuckQi.Data.Sql.EntityFramework.csproj index 4e6fe14..2b95696 100644 --- a/src/YuckQi.Data.Sql.EntityFramework/YuckQi.Data.Sql.EntityFramework.csproj +++ b/src/YuckQi.Data.Sql.EntityFramework/YuckQi.Data.Sql.EntityFramework.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 An implementation of YuckQi.Data for SQL databases using Entity Framework. YuckQi.Data https://github.com/Yuck/YuckQi.Data.git diff --git a/src/YuckQi.Data/YuckQi.Data.csproj b/src/YuckQi.Data/YuckQi.Data.csproj index 0061a2f..f254870 100644 --- a/src/YuckQi.Data/YuckQi.Data.csproj +++ b/src/YuckQi.Data/YuckQi.Data.csproj @@ -5,7 +5,7 @@ enable true Kevin J Lambert - 6.4.2 + 6.5.0 A .NET library of lightweight data access handlers which can be used to compose repositories and domain services. https://github.com/Yuck/YuckQi.Data.git git