OutWit.Common.Plugins.Abstractions 1.1.1

dotnet add package OutWit.Common.Plugins.Abstractions --version 1.1.1
                    
NuGet\Install-Package OutWit.Common.Plugins.Abstractions -Version 1.1.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="OutWit.Common.Plugins.Abstractions" Version="1.1.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="OutWit.Common.Plugins.Abstractions" Version="1.1.1" />
                    
Directory.Packages.props
<PackageReference Include="OutWit.Common.Plugins.Abstractions" />
                    
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 OutWit.Common.Plugins.Abstractions --version 1.1.1
                    
#r "nuget: OutWit.Common.Plugins.Abstractions, 1.1.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 OutWit.Common.Plugins.Abstractions@1.1.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=OutWit.Common.Plugins.Abstractions&version=1.1.1
                    
Install as a Cake Addin
#tool nuget:?package=OutWit.Common.Plugins.Abstractions&version=1.1.1
                    
Install as a Cake Tool

OutWit.Common.Plugins.Abstractions

This package contains the minimal set of shared interfaces, base classes, and attributes required to build plugins compatible with the OutWit.Common.Plugins system. It is intentionally lightweight to ensure your plugins do not depend on the main loader logic.

Key Components

  • IWitPlugin: The core interface that every plugin must implement. It defines the plugin lifecycle with methods for initialization, post-initialization, and unloading.
  • WitPluginBase: An abstract base class that provides a default empty implementation of IWitPlugin for convenience. You can override only the methods you need.
  • [WitPluginManifestAttribute]: A mandatory attribute for any plugin class. It defines essential metadata like the plugin's unique name, version, and load priority, making it discoverable by the plugin loader.
  • [WitPluginDependencyAttribute]: An optional attribute that can be used multiple times to declare dependencies on other plugins. It allows the loader to validate that required plugins are present before loading.

Installation

Add the package to your plugin's class library project using NuGet.

dotnet add package OutWit.Common.Plugins.Abstractions

How to Create a Plugin

  1. Create a new class library project.
  2. Add a reference to OutWit.Common.Plugins.Abstractions.
  3. Create a class that inherits from WitPluginBase (or directly implements IWitPlugin).
  4. Add the [WitPluginManifestAttribute] to your class, specifying a unique name.
  5. If needed, add [WitPluginDependencyAttribute] attributes to declare dependencies.
  6. Implement the Initialize and OnInitialized methods to register services and execute logic.

Example

C#

using Microsoft.Extensions.DependencyInjection;
using OutWit.Common.Plugins.Abstractions;
using OutWit.Common.Plugins.Abstractions.Attributes;
using OutWit.Common.Plugins.Abstractions.Interfaces;
using System;

[WitPluginManifest("MyFirstPlugin", Version = "1.0.0", Priority = 100)]
[WitPluginDependency("AnotherPlugin", MinimumVersion = "2.1.0")]
public class MyFirstPlugin : WitPluginBase
{
    // Use for registering services in DI.
    public override void Initialize(IServiceCollection services)
    {
        // Register services in the DI container
        services.AddSingleton<MyService>();
    }

    // Called after all plugins have been initialized.
    public override void OnInitialized(IServiceProvider serviceProvider)
    {
        // Logic that runs after all plugins are loaded
        var myService = serviceProvider.GetRequiredService<MyService>();
        myService.Run();
    }

    // Called just before the plugin is about to be unloaded.
    public override void OnUnloading()
    {
        // Perform cleanup here
    }
}

License

Licensed under the Apache License, Version 2.0. See LICENSE.

Attribution (optional)

If you use OutWit.Common.Plugins.Abstractions in a product, a mention is appreciated (but not required), for example: "Powered by OutWit.Common.Plugins.Abstractions (https://ratner.io/)".

Trademark / Project name

"OutWit" and the OutWit logo are used to identify the official project by Dmitry Ratner.

You may:

  • refer to the project name in a factual way (e.g., "built with OutWit.Common.Plugins.Abstractions");
  • use the name to indicate compatibility (e.g., "OutWit.Common.Plugins.Abstractions-compatible").

You may not:

  • use "OutWit.Common.Plugins.Abstractions" as the name of a fork or a derived product in a way that implies it is the official project;
  • use the OutWit.Common.Plugins.Abstractions logo to promote forks or derived products without permission.
Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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 (2)

Showing the top 2 NuGet packages that depend on OutWit.Common.Plugins.Abstractions:

Package Downloads
OutWit.Common.Plugins

A robust and flexible plugin system for .NET. Features dynamic discovery from directories, sophisticated dependency resolution (validates versions and detects circular dependencies), and isolated loading via AssemblyLoadContext to enable hot-reloading and unloading of plugins.

OutWit.Engine.Interfaces

Core interface definitions and contracts for the WitEngine distributed computing system. Provides interfaces for activities, variables, jobs, processing, benchmarking, and plugin development.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.1 110 1/25/2026
1.1.0 335 11/14/2025
1.0.2 191 8/15/2025
1.0.1 119 8/1/2025
1.0.0 108 8/1/2025