StructForge 1.0.0
See the version list below for details.
dotnet add package StructForge --version 1.0.0
NuGet\Install-Package StructForge -Version 1.0.0
<PackageReference Include="StructForge" Version="1.0.0" />
<PackageVersion Include="StructForge" Version="1.0.0" />
<PackageReference Include="StructForge" />
paket add StructForge --version 1.0.0
#r "nuget: StructForge, 1.0.0"
#:package StructForge@1.0.0
#addin nuget:?package=StructForge&version=1.0.0
#tool nuget:?package=StructForge&version=1.0.0
StructForge
StructForge is a lightweight, educational, and practical C# library for learning and experimenting with fundamental data structures and algorithms. It provides a range of generic collections, sorting algorithms, and interfaces for building your own high-level structures.
Features
Collections
- Lists:
SfList<T>,SfLinkedList<T>(with nodes and full linked list operations) - Stacks & Queues:
SfStack<T>,SfQueue<T> - Heaps & Priority Queues:
SfBinaryHeap<T>,SfMaxHeap<T>,SfMinHeap<T>,SfPriorityQueue<TItem, TPriority> - Binary Search Trees:
SfBinarySearchTree<T>
Sorting Algorithms
- QuickSort
- TreeSort
Interfaces
IDataStructure<T>: Base interface for all collectionsIHeap<T>: Generic heap interfaceILinkedList<T>: Doubly-linked list interfaceIQueue<T>: Queue interfaceISequence<T>: Sequence interfaceIStack<T>: Stack interfaceITree<T>: Tree interface
Key Capabilities
- Fully generic implementations
- Iteration and enumeration support
- Custom comparers for heaps, priority queues, and sorting
- Educational and practical reference for learning C# data structures
Installation
You can install the latest version via NuGet:
dotnet add package StructForge
Or clone the repository and include the StructForge project in your solution:
git clone https://github.com/yourusername/StructForge.git
Usage Examples
Linked List
var list = new SfLinkedList<int>();
list.AddLast(1);
list.AddLast(2);
list.AddFirst(0);
foreach (var item in list)
Console.WriteLine(item); // 0, 1, 2
Priority Queue
var pq = new SfPriorityQueue<string, int>();
pq.Enqueue("low", 5);
pq.Enqueue("high", 1);
pq.Enqueue("medium", 3);
foreach (var item in pq.EnumerateByPriority())
Console.WriteLine(item); // "high", "medium", "low"
QuickSort
int[] arr = { 5, 2, 9, 1, 5, 6 };
Quicksort.Sort(arr);
Console.WriteLine(string.Join(", ", arr)); // 1, 2, 5, 5, 6, 9
Contribution
Contributions are welcome! Feel free to open issues, add features, or improve existing code. Keep in mind that this library is primarily educational.
License
MIT License – see LICENSE for details.
| 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.
Initial release v1.0