DoubleSharp 0.0.1-beta1
This is a prerelease version of DoubleSharp.
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package DoubleSharp --version 0.0.1-beta1
NuGet\Install-Package DoubleSharp -Version 0.0.1-beta1
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="DoubleSharp" Version="0.0.1-beta1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add DoubleSharp --version 0.0.1-beta1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: DoubleSharp, 0.0.1-beta1"
#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.
// Install DoubleSharp as a Cake Addin #addin nuget:?package=DoubleSharp&version=0.0.1-beta1&prerelease // Install DoubleSharp as a Cake Tool #tool nuget:?package=DoubleSharp&version=0.0.1-beta1&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Overview
DoubleSharp provides convenience features for:
- LINQ:
ToDictionary
convertingIEnumerable
s of tuples intoDictionary
s automatically;Shuffle
andShuffled
providing in-place and copy shuffles;Flatten
reducing the nesting ofIEnumerable
s; and much more - Concurrency:
Locked
extension method on objects allowing locking as an expression;Increment
/Decrement
/Add
/And
/Or
providing inline atomic operations - Functional:
Compose
allowing function composition - Progress:
WithProgress
andWithTimedProgress
extension methods onIEnumerable
/ICollection
providing parallel-friendly progress bars - Random:
Rng
providing a static class with automatic per-CPU seeds - Pretty:
ToPrettyString
extension method for all objects to convert it to a human-readable form;Print
andPrettyPrint
extension methods (aliases) to print that to the console, akin to Python'spprint
module - Buffers:
Cast
andAsEnumerable
extensions forMemory<T>
andSpan<T>
,HexDump
(for Console/TextWriter output) andToHexDump
(for string creation) for all common unmanaged buffers - MathPlus: Swizzles for
Vector2/3/4
, tuple<->Vector conversions, Vector deconstruction,Centroid
extension method forIEnumerable<Vector2/3/4>
,Map
for Vector to perform elementwise transformation, bit operations for unsigned integer types,Ceil
/Floor
/Round
extensions for float/double, andCeilInt
/FloorInt
/RoundInt
extensions for floor/double to int
Our general goal is to make C# even easier to use than it is right now. If it's something we have to write in several projects, it should be here instead.
Usage
Simply reference the DoubleSharp
package on NuGet and then import the namespaces with the functionality you need.
Check out the progress bar example or the unit tests for use cases!
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | 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 was computed. 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net7.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.
Version | Downloads | Last updated |
---|---|---|
0.0.3 | 137 | 4/6/2024 |
0.0.2 | 115 | 4/6/2024 |
0.0.1 | 306 | 12/21/2022 |
0.0.1-beta1 | 133 | 12/20/2022 |
0.0.1-alpha8 | 133 | 12/19/2022 |
0.0.1-alpha7 | 131 | 12/19/2022 |
0.0.1-alpha6 | 125 | 12/19/2022 |
0.0.1-alpha5 | 129 | 12/19/2022 |
0.0.1-alpha4 | 120 | 12/19/2022 |
0.0.1-alpha3 | 136 | 12/19/2022 |
0.0.1-alpha2 | 139 | 12/18/2022 |
0.0.1-alpha | 131 | 12/18/2022 |