Repository navigation
Home
The ONIXLabs .NET Library is a suite of general-purpose, production-ready libraries for modern .NET application development, with a strong emphasis on correctness, composability, and value semantics. The libraries integrate cleanly into both small utilities and large-scale systems without imposing architectural constraints or framework lock-in.
This wiki is the conceptual and reference documentation for the library. Use the sections below to find an overview of each package, the types it contributes, and the runtimes it supports.
| Package | Description |
|---|---|
| OnixLabs.Core | Foundational primitives, patterns, and extensions that fill gaps in the Base Class Library. |
| OnixLabs.DependencyInjection | Configuration-driven service registration for Microsoft's DI abstractions. |
| OnixLabs.Numerics | Arbitrary-precision numbers, extended-width integers, and generic math utilities. |
| OnixLabs.Security | Non-cryptographic security utilities for safe generation of security values. |
| OnixLabs.Security.Cryptography | Strongly typed cryptographic primitives and structures with value semantics. |
At a high level, the library provides:
- Foundational primitives and patterns missing or underrepresented in the BCL.
- Functional and value-oriented abstractions for safer code.
- High-precision numeric and generic math utilities.
- Security and cryptography APIs with strong typing and value semantics.
- Infrastructure helpers that reduce boilerplate while preserving clarity.
| Principle | Description |
|---|---|
| Correctness | APIs are designed to make invalid states unrepresentable and to surface failure explicitly rather than silently. |
| Composability | Types are small, orthogonal, and intended to combine cleanly without coupling to a particular framework. |
| Value semantics | Equality and comparison are based on value, not reference, through interfaces such as IValueEquatable<T> and IValueComparable<T>. |
| No lock-in | The libraries add capability without dictating application architecture. |
| Item | Supported |
|---|---|
| Target frameworks | .NET 8.0, .NET 9.0, .NET 10.0, .NET 11.0 |
| Language version | C# 15 |
| Nullable reference types | Enabled |
| License | Apache-2.0 |
All packages are published to NuGet.
Install the packages you need with the .NET CLI:
dotnet add package OnixLabs.Core
dotnet add package OnixLabs.DependencyInjection
dotnet add package OnixLabs.Numerics
dotnet add package OnixLabs.Security
dotnet add package OnixLabs.Security.CryptographyONIXLabs .NET Library · Repository · NuGet · License (Apache-2.0)
Copyright © ONIXLabs 2020. Licensed under the Apache License, Version 2.0.
- Enumeration<T>
- Optional<T>
- OptionalEqualityComparer<T>
- OptionalExtensions
- Result
- Result<T>
- ResultEqualityComparer<T>
- ResultExtensions
- Specification<T>
- Preconditions
- IValueEquatable<T>
- IValueComparable<T>
- IBinaryConvertible
- ISpanBinaryConvertible
- IMemoryBinaryConvertible
- ArrayExtensions
- ComparableExtensions
- DateTimeExtensions
- ISpanParsableExtensions
- ObjectExtensions
- RandomExtensions
- ReadOnlySequenceExtensions
- ReadOnlySpanExtensions
- StringExtensions
- Base16
- Base32
- Base58
- Base64
- IBaseCodec
- IBaseValue
- IBaseValue<T>
- Base16Codec
- Base32Codec
- Base58Codec
- Base64Codec
- Base16FormatProvider
- Base32FormatProvider
- Base58FormatProvider
- Base64FormatProvider
- EncodingExtensions
- ReadOnlySpanExtensions
- StringBuilderExtensions
- BigDecimal
- BigDecimalEqualityComparer
- BigDecimalOrdinalityComparer
- NumberInfo
- NumberInfoEqualityComparer
- NumberInfoOrdinalityComparer
- Int256
- Int512
- UInt256
- UInt512
- Float128
- Float256
- GenericMath
- NumericsExtensions
- ConversionMode
- ScaleMode
- Hash
- NamedHash
- Sha3
- Sha3Hash224
- Sha3Hash256
- Sha3Hash384
- Sha3Hash512
- Sha3Shake128
- Sha3Shake256
- MerkleTree
- MerkleTree<T>
- PrivateKey
- PublicKey
- NamedPrivateKey
- NamedPublicKey
- EcdhPrivateKey
- EcdhPublicKey
- EcdsaPrivateKey
- EcdsaPublicKey
- EddsaPrivateKey
- EddsaPublicKey
- RsaPrivateKey
- RsaPublicKey
- DigitalSignature
- DigitalSignatureAndPublicKey
- Salt
- Secret
- ICryptoPrimitive<T>
- IHashable
- IEcdhPrivateKey
- IEcdsaPrivateKey
- IEddsaPrivateKey
- IRsaPrivateKey
- IPrivateKeyDerivable<T>
- IPrivateKeyExportable
- IPrivateKeyImportable<T>
- IPrivateKeyPemImportable<T>
- IPrivateKeyPkcs8Exportable
- IPrivateKeyPkcs8Importable<T>
- IPrivateKeyPkcs8PemExportable
- IPrivateKeyRawExportable
- IPrivateKeyRawImportable<T>
- IPrivateKeyRawPemExportable
- IEcdhPublicKey
- IEcdsaPublicKey
- IEddsaPublicKey
- IRsaPublicKey
- IPublicKeyExportable
- IPublicKeyImportable<T>
- IPublicKeyPemExportable
- IPublicKeyPemImportable<T>
- IPublicKeyRawExportable
- IPublicKeyRawImportable<T>
- HashAlgorithmExtensions
- ReadOnlySpanExtensions