TaskRunnerSharp 1.0.5
dotnet add package TaskRunnerSharp --version 1.0.5
NuGet\Install-Package TaskRunnerSharp -Version 1.0.5
<PackageReference Include="TaskRunnerSharp" Version="1.0.5" />
<PackageVersion Include="TaskRunnerSharp" Version="1.0.5" />
<PackageReference Include="TaskRunnerSharp" />
paket add TaskRunnerSharp --version 1.0.5
#r "nuget: TaskRunnerSharp, 1.0.5"
#:package TaskRunnerSharp@1.0.5
#addin nuget:?package=TaskRunnerSharp&version=1.0.5
#tool nuget:?package=TaskRunnerSharp&version=1.0.5
TaskRunnerSharp
✨ Overview
TaskRunnerSharp is a minimalistic library that makes it easy to manage, run, and monitor multiple asynchronous or synchronous tasks, with built-in logging and result aggregation.
Whether you're handling fire-and-forget jobs or collecting results from parallel computations, TaskRunnerSharp provides a clean, reliable API.
📦 Installation
Install via NuGet Package Manager:
dotnet add package TaskRunnerSharp
Or via Visual Studio ➔ Manage NuGet Packages ➔ Search for TaskRunnerSharp
.
🚀 Features
- Manage and orchestrate multiple tasks (
Task
andTask<T>
). - Collect results from successfully completed typed tasks.
- Execute tasks synchronously or asynchronously (
Run
/RunAsync
). - Thread-safe internal operations.
- Built-in execution logging (tasks added, started, completed, or failed).
- Easy to reset with
Clear()
.
⚡ Quick Start
using TaskRunnerSharp;
var runner = new TaskRunner();
// Add tasks
runner.Add(() => Console.WriteLine("Running Action 1"));
runner.Add(() => 123);
runner.Add(() => "Hello TaskRunnerSharp!");
// Run all tasks
runner.Run(); // or await runner.RunAsync();
// Access typed task results
foreach (var result in runner.Results)
{
Console.WriteLine($"Result: {result}");
}
// View logs
foreach (var log in runner.Logs)
{
Console.WriteLine(log);
}
// Clear all tasks
runner.Clear();
📄 Overview
Method / Property | Description |
---|---|
Add(Action) |
Adds an action. |
Add<T>(Func<T>) |
Adds a func (returns a value). |
Add(Task) |
Adds a non-returning task. |
Add<T>(Task<T>) |
Adds a typed task that returns a value. |
Run() |
Runs all tasks synchronously. |
RunAsync() |
Runs all tasks asynchronously. |
Results |
Retrieves a list of results from successfully completed typed tasks. |
Logs |
Retrieves execution logs. |
Clear() |
Removes all stored tasks and logs the operation. |
📝 License
This project is licensed under the MIT License.
TaskRunnerSharp — keeping your parallelism simple and reliable.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | 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 was computed. 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 was computed. 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. |
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.