157 Commits

Author SHA1 Message Date
Developer 02
55eb250d7e Deprecate controllers/services; simplify generics
Added `[Obsolete("Use MediatR")]` attributes to various controller and service classes to indicate deprecation in favor of MediatR. Simplified generic type constraints in `CRUDControllerBase` and related files by removing `IUnique<TId>`. Improved structure and documentation in `CSPMiddleware.cs`. Introduced new extension methods in `EntityExtensions.cs` for safer retrieval of 'Id' properties. Removed `IUnique.cs` interface and updated project dependencies in `DigitalData.Core.Application.csproj` for caching. Overall, these changes enhance code maintainability and clarity.
2025-05-16 14:54:31 +02:00
Developer 02
e0c1b856ad Remove ServiceResultExtensions class and Try method
The `ServiceResultExtensions` class has been removed from the
`DigitalData.Core.Abstractions` namespace. This class included a
static method `Try<T>` for handling nullable results, which has
now been eliminated. This change may indicate a refactoring
or a new approach to managing nullable results in the codebase.
2025-05-16 13:12:02 +02:00
Developer 02
3a1aeb7ac3 Refactor namespaces and enhance application structure
This commit reorganizes namespaces from `DigitalData.Core.Abstractions` and `DigitalData.Core.DTO` to `DigitalData.Core.Application.Interfaces` and `DigitalData.Core.Application.DTO`, improving maintainability and clarity.

Updated using directives across multiple files to reflect the new structure, ensuring functionality remains intact.

Project references in `DigitalData.Core.API.csproj` have been consolidated to include the new Application project.

Introduced new classes and interfaces such as `BaseDTO`, `CookieConsentSettings`, `DataResult`, `Notice`, and `Result` to enhance data transfer and service result handling.

Updated `IRepository`, `ICRUDRepository`, and `IEntityMapper` interfaces to facilitate CRUD operations and entity mapping.

Added extension methods in `Extensions.cs` to improve repository usability.

New interfaces for HTTP client services have been added, enhancing external API call handling.

Overall, these changes reflect a significant restructuring aimed at improving organization and preparing for future development.
2025-05-16 11:24:58 +02:00
Developer 02
246184165f feat(Core.Abstractions): Upgrade auf 3.6 2025-04-28 16:11:26 +02:00
Developer 02
9d36ced82f feat: Hinzufügen von Erweiterungsmethoden zum Abrufen von Konfigurationsoptionen von IServiceProvider
- Implementiert GetOptions<TOptions> zum Abrufen von Optionen oder null.
- Implementiert GetRequiredOptions<TOptions> für den Abruf von Optionen oder das Auslösen einer Ausnahme.
2025-04-28 16:10:31 +02:00
Developer 02
c81ff2c628 feat(ConfigurationExtension): Hinzufügen der Klasse ConfigurationExtension mit der Methode GetOrDefault zum sichereren Abrufen von Konfigurationen
- Einführung einer neuen statischen Klasse ConfigurationExtension im Namespace DigitalData.Core.Abstractions.
- Hinzufügen der GetOrDefault-Erweiterungsmethode zu IConfiguration, die eine einfachere Abfrage von Konfigurationswerten mit Standardverhalten ermöglicht, wenn diese nicht gefunden werden.
- Aktualisierung der Versionsnummern auf 3.5.0 in den Projektdateien.
2025-04-28 15:44:01 +02:00
Developer 02
653665bb25 refactor(LazyServiceProvider.cs): rename DeferredServiceProvider.cs 2025-04-28 14:58:30 +02:00
Developer 02
17edf605e7 chore(Abstractions): Aktualisiert auf 3.4.4 2025-04-28 14:57:29 +02:00
Developer 02
b41373339e feat(core): DeferredServiceProvider für verzögerte IServiceProvider-Initialisierung hinzugefügt 2025-04-28 14:56:25 +02:00
Developer 02
fb9449d701 chore: upradge versions 2025-04-22 23:05:04 +02:00
Developer 02
72f735272f feat(Repository): Add and implement ReadOrDefaultAsync method.
- add read method can map for each
2025-04-22 23:04:11 +02:00
Developer 02
3c1bbc1151 feat(Repository): CreateAsync-Methoden für DTO wurden in Erweiterungsmethoden konvertiert 2025-04-22 11:21:21 +02:00
Developer 02
5465fe5b49 feat(IEntityMapper): Erstellt, um Mapper zu abstrahieren.
- Integriert in IRepository und Repository
2025-04-22 11:10:55 +02:00
Developer 02
85787e7054 feat(DbRepositoryTests): ReadAsync_ShouldReturnUpdated und ReadAsync_ShouldNotReturnDeleted Tests 2025-04-22 10:09:47 +02:00
Developer 02
476c86ff0a feat: Verbesserung von IRepository mit neuen asynchronen Methoden und Erweiterungen
Aktualisiert IRepository<TEntity> um UpdateAsync<TDto>, DeleteAsync<TDto> und eine neue Überladung von ReadAsync. Die frühere ReadAsync-Überladung für Core.Tests.Mock.User wurde entfernt.

Einführung einer neuen Extensions-Klasse mit Methoden für ReadFirstOrDefaultAsync, ReadFirstAsync, ReadSingleOrDefaultAsync und ReadSingleAsync unter Nutzung der aktualisierten ReadAsync-Methode.
2025-04-17 16:24:52 +02:00
Developer 02
9376fcff86 Enhance IRepository and update DbRepositoryTests
- Added ReadAsync method to IRepository for user retrieval.
- Introduced _userRepo field in DbRepositoryTests for better clarity.
- Modified Setup method to initialize _userRepo from the service provider.
- Updated CreateAsync_ShouldNotThrow to use _userRepo.
- Added ReadAsync_ShouldReturnCreated test for user retrieval validation.
2025-04-17 16:00:59 +02:00
Developer 02
f5b202c325 Enhance IRepository and DbRepository with DTO support
Updated IRepository<TEntity> to include new generic methods for creating and reading entities from DTOs. Modified UpdateAsync to accept DTOs instead of generic types. Implemented corresponding methods in DbRepository<TDbContext, TEntity> for mapping DTOs to entities during creation and updating processes.
2025-04-17 13:30:35 +02:00
Developer 02
fffbdf752f Revert "Add mapping methods to IRepository and DbRepository"
This reverts commit 6916e169b17fc22997f3fed178863f2e1ed5d059.
2025-04-17 13:15:22 +02:00
Developer 02
6916e169b1 Add mapping methods to IRepository and DbRepository
Updated the `IRepository<TEntity>` interface to include two new mapping methods: `Map<TSource>(TSource source)` and `Map<TDto>(TEntity source)`.

Implemented these methods in the `DbRepository<TDbContext, TEntity>` class, utilizing a `Mapper` for conversions between source types and entity types, as well as between entity types and DTOs.
2025-04-17 13:01:51 +02:00
Developer 02
0c529b199b Bump version numbers and enhance repository interfaces
- Incremented version numbers in project files for updates.
- Marked `ICRUDRepository` as obsolete; use `IRepository` instead.
- Improved parameter names and signatures in `IRepository`.
- Changed access modifiers in `DbRepository` for broader access.
- Updated `CreateAsync` and `UpdateAsync` methods for async operations.
- Implemented `ReadAsync` and `DeleteAsync` methods in `DbRepository`.
- Minor whitespace change in `.csproj` files.
- Retained package description in `DigitalData.Core.Infrastructure.csproj`.
2025-04-17 12:53:40 +02:00
Developer 02
352b59dfdf Refactor IRepository to simplify CreateAsync methods
Updated IRepository<TEntity> to remove generic type parameters
from CreateAsync methods, now directly accepting TEntity.
Corresponding changes made in DbRepository to align method
signatures. Implementations still throw NotImplementedException.
2025-04-16 09:38:07 +02:00
Developer 02
1b793e2b75 Add CancellationToken support to IRepository methods
Updated the IRepository<TEntity> interface to include an optional CancellationToken parameter in the asynchronous methods: CreateAsync, ReadAsync, UpdateAsync, and DeleteAsync. Modified the DbRepository<TDbContext, TEntity> class to align with these changes, ensuring method signatures are consistent with the interface.
2025-04-16 09:17:38 +02:00
Developer 02
162da9a16c Ablehnung von ICRUDRepository; Einführung der IRepository-Schnittstelle
Die `ICRUDRepository`-Schnittstelle wurde als veraltet markiert, was bedeutet, dass sie zugunsten der neuen `IRepository`-Schnittstelle abgelehnt wird. Die „IRepository“-Schnittstelle bietet eine verbesserte Abstraktion und Flexibilität, die Methoden zum Erstellen, Lesen, Aktualisieren und Löschen von Entitäten mit Unterstützung für asynchrone Operationen umfasst.
2025-04-15 18:40:50 +02:00
Developer 02
c0524cbca2 Update target frameworks to include .NET 9.0
Updated multiple project files to support .NET 9.0 alongside .NET 7.0 and .NET 8.0. Affected files include:
- DigitalData.Core.API.csproj
- DigitalData.Core.Abstractions.csproj
- DigitalData.Core.Application.csproj
- DigitalData.Core.Client.csproj
- DigitalData.Core.DTO.csproj
- DigitalData.Core.Infrastructure.csproj

This change enables the use of new features and improvements in .NET 9.0.
2025-04-15 16:19:23 +02:00
Developer 02
3f8145e6dc chore(DigitalData.Core.Abstractions): Aktualisiert auf Version 3.4.0 2025-03-14 14:08:54 +01:00
Developer 02
9ec9bcd474 chore(DigitalData.Core.Abstractions.Security): DigitalData.Core.Abstractions/Security zu einem eigenen Projekt gemacht 2025-03-14 12:04:38 +01:00
Developer 02
b8de148c52 refactor: Umbenennung von CryptoFactory in RSAPool und ICryptoFactory in IAsymmetricKeyPool 2025-03-14 10:47:28 +01:00
Developer 02
528a346883 feat(ServiceResultExtensions): Erstellt, um die Serviceergebnisse zu verwalten.
- Aufgerüstet auf 3.3.0
2025-01-23 11:29:57 +01:00
Developer 02
53427282c5 refactor(Abstraktionen): hochgestuft auf 3.2 2025-01-20 10:17:10 +01:00
Developer 02
90c85814b0 refactor(DirectorySearchService): Methoden asynchron gemacht 2025-01-17 11:24:30 +01:00
Developer 02
f1efbae6a4 feat(Sicherheit): Paketdefinition hinzugefügt. 2025-01-14 20:14:59 +01:00
Developer 02
051567aa0a refactor(Abstraktionen): hochgestuft auf 3.1 2025-01-14 19:51:58 +01:00
Developer 02
287871ddc6 refactor(TokenDescriptor): ApiRoute-Eigenschaft entfernt 2025-01-14 19:45:44 +01:00
Developer 02
a0ad8d732d refactor(RSATokenDescriptor): Lifetime-Eigenschaft hinzugefügt 2025-01-14 17:04:54 +01:00
Developer 02
3ad08e2a86 feat(AsymmetricTokenValidator): SecurityKey-Eigenschaft hinzugefügt. 2025-01-13 09:52:52 +01:00
Developer 02
b90a52412c feat(IAsymmetricTokenDescriptor): Methode Validator.get mit Lazy Loading hinzugefügt. 2025-01-10 23:32:53 +01:00
Developer 02
39091ff5cf refactor(IAsymmetricKey): Id nullbar gemacht.
- Benennung der perm-Datei aktualisiert.
2025-01-10 15:47:02 +01:00
Developer 02
66e3c771dd refactor(IAsymmetricKey): Die Implementierung von IUniqueSecurityContext wurde entfernt und stattdessen die Eigenschaft Id hinzugefügt.
- Aktualisierte verwandte Implementierungen.
2025-01-09 22:57:04 +01:00
Developer 02
5981ba7a8d refactor(Abstractions.Security): Unnötige public Schlüsselwörter in Schnittstellen entfernt. 2025-01-09 22:27:33 +01:00
Developer 02
21e164ceb7 refactor(IAsymmetricKey): Unnötige Initor-Methoden entfernt. 2025-01-09 22:15:45 +01:00
Developer 02
7f9459f6cf feat(SecurityExtensions): Erforderliche WriteToken-Methoden über Erweiterungen anstelle der Schnittstellenimplementierung hinzugefügt 2025-01-09 20:30:38 +01:00
Developer 02
079f0c69c7 fix(Kryptograph): Umbenannt in Krypto-Fabrik. 2025-01-09 20:10:45 +01:00
Developer 02
d98b3f2867 fix(JwtSignatureHandler): Aktualisierte Methoden, um IAsymmetricTokenDescriptor verwenden zu können 2025-01-09 19:54:05 +01:00
Developer 02
3761c13dba refactor(ICryptograph): Eigenschaft „TokenDescriptors“ hinzugefügt. 2025-01-09 19:34:29 +01:00
Developer 02
8acbbaeb2e refactor(IAsymmetricTokenDescriptor): Erforderliche Proportionen für SecurityTokenDescriptor-Zuordnung hinzugefügt. 2025-01-09 19:16:56 +01:00
Developer 02
60e1ec78b3 refactor(Kryptograph): Entfernte Verschlüsselungen. 2025-01-09 18:52:59 +01:00
Developer 02
87ad45f42a refactor(RSATokenDescriptor): Die Klasse RSA Token Descriptor wurde erstellt und die Funktionen wurden dorthin verschoben, um eine einfache und saubere Konfiguration zu ermöglichen. 2025-01-09 17:59:13 +01:00
Developer 02
2557525f06 refactor(PrivateKeyTokenDescriptor): superwarning zur Deaktivierung der Warnung vor Null 2025-01-09 11:08:06 +01:00
Developer 02
7a938f0379 refactor(Privatekey): Die Klasse encryptor wurde erstellt und die Verschlüsselungsfunktionen wurden zur einfachen und sauberen Konfiguration dorthin verschoben. 2025-01-08 20:03:25 +01:00
Developer 02
9f0facc487 refactor(Privatekey): Die Klasse decryptor wurde erstellt und die Verschlüsselungsfunktionen für eine einfache und saubere Konfiguration dorthin verschoben. 2025-01-08 18:45:36 +01:00