OptimusFramework.AppService.Generic 2.0.1

dotnet add package OptimusFramework.AppService.Generic --version 2.0.1
                    
NuGet\Install-Package OptimusFramework.AppService.Generic -Version 2.0.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="OptimusFramework.AppService.Generic" Version="2.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="OptimusFramework.AppService.Generic" Version="2.0.1" />
                    
Directory.Packages.props
<PackageReference Include="OptimusFramework.AppService.Generic" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add OptimusFramework.AppService.Generic --version 2.0.1
                    
#r "nuget: OptimusFramework.AppService.Generic, 2.0.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package OptimusFramework.AppService.Generic@2.0.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=OptimusFramework.AppService.Generic&version=2.0.1
                    
Install as a Cake Addin
#tool nuget:?package=OptimusFramework.AppService.Generic&version=2.0.1
                    
Install as a Cake Tool

OptimusFramework.AppService.Generic

Generic application service implementations for the Optimus Framework. Provides Template Method pattern-based CRUD and Store behaviors with dynamic pagination, validation pipeline, and lifecycle hooks.

Features

  • CRUD Behavior: ServiceCrudBehavior implementing the full CRUD lifecycle with pre/post hooks
  • Store Behavior: ServiceStoreBehavior for insert/update operations with validation
  • List Behavior: ServiceListBehavior with dynamic query building and pagination via System.Linq.Dynamic
  • Template Method Pattern: Override lifecycle hooks (OnPreCreate, OnPostCreate, OnPreUpdate, OnPostUpdate, OnPreStore, OnPostStore, OnPreSaveChanges, OnPostSaveChanges)
  • Message Processing: MessageProcessor for validation message pipeline
  • Pre-built Specializations: Ready-to-use classes for Entity, IdEntity, and NameDesc patterns

Key Classes

Class Description
AppServiceBase Base service with IRepoTenant and IDisposable
AppServiceUoF<TUnitOfWork> Service base with Unit of Work access
ServiceCrudBehavior Full CRUD with lifecycle hooks and validation
ServiceCrudBehaviorUoF CRUD with Unit of Work
ServiceCrudBehaviorRepo CRUD with Repository
ServiceStoreBehavior Store (insert/update) with hooks
ServiceListBehavior List with dynamic filtering and pagination
MessageProcessor IMessageProcessor implementation

Installation

dotnet add package OptimusFramework.AppService.Generic

Usage

using OptimusFramework.AppService.Generic;

public class ProductService : ServiceCrudBehaviorUoF<IMyUnitOfWork, ProductParam, ProductDto, Product, int, ProductFilter>
{
    protected override void OnPreCreate(Product entity, ProductParam param)
    {
        entity.Code = GenerateCode();
    }

    protected override IQueryable<Product> FindQuery(ProductFilter filter)
    {
        var query = Context.Products.AsQueryable();
        if (!string.IsNullOrEmpty(filter.Name))
            query = query.Where(p => p.Name.Contains(filter.Name));
        return query;
    }
}
Product Compatible and additional computed target framework versions.
.NET 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (5)

Showing the top 5 NuGet packages that depend on OptimusFramework.AppService.Generic:

Package Downloads
OptimusFramework.AppService.EFCore

Package Description

OptimusLog.AppService

Package Description

OptimusSecurity.AppService

Package Description

SfeAuth.Core.Generic.Api

Package Description

SfeAuth.Core.Domain

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.0.1 147 2/18/2026
2.0.0 129 2/18/2026