175 Commits

Author SHA1 Message Date
5567f6731b chore(Core.Abstractions): bump to 4.3.0 2025-10-29 16:25:32 +01:00
fc297d92fa feat(factory): add IServiceScopeFactory property to Factory class
Added ScopeFactory property to the Factory class to expose IServiceScopeFactory through GetRequiredService<IServiceScopeFactory>().
This enables scoped service creation from the factory instance.
2025-10-29 16:08:43 +01:00
50a056d110 feat(Factory): add PostBuildBehavior to control post-build modification behavior in Factory
Introduced PostBuildBehavior enum and BehaveOnPostBuild() method to configure behavior when modifying the service collection after the service provider is built.
Replaced EnsureNotBuilt() with EnsureBuilt() to support configurable handling (throw exception or ignore).
This improves flexibility in scenarios where post-build service modifications should be optionally allowed or silently ignored.
2025-10-29 15:57:36 +01:00
62e43024a6 chore(Abstractions): bump to 4.2.0 2025-10-23 10:29:41 +02:00
10ff9b9745 refactor(Factory): rename Instance as Shared 2025-10-23 10:19:59 +02:00
ea2340974a refactor(FactoryTests): created unit tests for Factory 2025-10-23 10:18:14 +02:00
fbf9488c55 feat(Factory): prevent service modifications after provider is built
Added an `IsBuilt` property and `EnsureNotBuilt()` helper to `Factory` class
to restrict modifications to the service collection once the service provider
has been built. This ensures immutability and prevents runtime inconsistencies
after initialization.
2025-10-23 09:53:50 +02:00
ddbb70081e fix(factory): return requested service from IServiceProvider in GetService method 2025-10-23 09:49:38 +02:00
c538a8df8c feat(Factory): add Factory class implementing IServiceProvider and IServiceCollection
- Introduced Factory class in DigitalData.Core.Abstractions namespace
- Implements both IServiceProvider and IServiceCollection interfaces
- Provides singleton instance via static readonly Instance property
- Supports lazy initialization of IServiceProvider using Lazy<T>
- Includes full collection management (Add, Remove, Clear, etc.)
- Ensures compatibility with both .NET and .NET Framework via conditional directives
2025-10-23 09:47:18 +02:00
f500d9d974 chore(Abstractions): update package references and add dependency injection packages
- Added Microsoft.Extensions.DependencyInjection and Abstractions for net462
- Added Microsoft.Extensions.DependencyInjection for net7.0, net8.0, and net9.0
- Updated Microsoft.Extensions.* package versions for net8.0 and net9.0 to 9.0.10
2025-10-23 09:27:26 +02:00
Developer 02
0dd4930f1b refactor(DigitalData.Core.Abstraction.Application): update to support net 462 2025-09-30 16:52:02 +02:00
c95f018413 refactor(Core.Abstractions): update to support net 4.6.2 2025-09-15 10:16:28 +02:00
b99ff91841 chore bump to related version 2025-09-12 15:09:14 +02:00
1c69eb48cd move IEntity and IDto to Core.Abstractionns 2025-09-12 15:05:40 +02:00
Developer 02
5e2ebd07db Update NuGet package description for clarity
Modified the description in the `DigitalData.Core.Abstractions.csproj` file to provide a more concise statement about the package, removing details about Clean Architecture principles.
2025-05-20 10:44:56 +02:00
Developer 02
43e714b061 Update package references by target framework version
Modified `DigitalData.Core.Abstractions.csproj` to conditionally include package references for `Microsoft.Extensions.Caching.Memory` and `Microsoft.Extensions.Configuration.Binder` based on the target framework (`net7.0`, `net8.0`, `net9.0`). This change enhances compatibility and version management for different .NET versions.
2025-05-20 10:44:28 +02:00
Developer 02
7a7f564f82 Bump version to 4.0.0 in project file
Updated versioning information in `DigitalData.Core.Abstractions.csproj` from 3.6.0 to 4.0.0, including changes to `<Version>`, `<AssemblyVersion>`, and `<FileVersion>`.
2025-05-20 10:36:20 +02:00
Developer 02
4afeddb7f9 Enhance documentation and introduce IReadQuery interface
Updated XML documentation in ConfigurationExtension.cs for better clarity.
Removed the old implementation and retained the functionality of GetOrDefault<T>.

Introduced a new IReadQuery<TEntity> interface in IReadQuery.cs,
providing methods for both asynchronous and synchronous entity queries,
along with comprehensive documentation for each method.
2025-05-20 09:56:54 +02:00
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