Jakar.Spans 10.1.0

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

Jakar.Spans

Allocation-free span primitives. The types live in the Jakar.Extensions namespace. Jakar.Json and Jakar.Extensions both build on this package. Jakar.Extensions type-forwards ValueStringBuilder and Sizes here, so binaries compiled against an older Jakar.Extensions keep working.

The only dependency is JetBrains.Annotations, for its code-analysis attributes.

Type Purpose
ValueStringBuilder A stack-only UTF-16 builder: starts from a caller buffer (stackalloc char[256]) or a pooled array, and formats values in place through ISpanFormattable.
ValueUtf8Builder The UTF-8 counterpart: Append("..."u8), UTF-16 text transcoded in place, values formatted through IUtf8SpanFormattable.
ValueSpanReader<T> A forward cursor over a ReadOnlySpan<T> (char, byte, ...): TryPeek, TryRead, TryReadExact, TryReadTo, SkipWhile, and checkpoints with Position / Rewind. Try* members never throw and don't move on failure.
Sizes Maximum formatted lengths per type, used to pre-size buffers.
using ValueUtf8Builder builder = new(stackalloc byte[256]);
builder.Append("{\"total\" : "u8).AppendUtf8Formattable(12.5m).Append((byte)'}');

ValueSpanReader<char> reader = new("key=value");
reader.TryReadTo('=', out ReadOnlySpan<char> key);   // "key"; reader.Remaining is "value"

Versions follow <.NET major>.<library major>.<library minor> (see the repository README).

Product Compatible and additional computed target framework versions.
.NET 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 Jakar.Spans:

Package Downloads
Jakar.Extensions

Extensions to aid in development.

Jakar.Json

A reflection-free, allocation-free JSON serializer: [JsonModel] source-generates idempotent readers and writers (UTF-16 and UTF-8) that implement ISpanFormattable / ISpanParsable, plus a zero-allocation JSON tape and a Newtonsoft-style DOM. Also includes Native AOT friendly System.Text.Json models (IJsonModel<TSelf>, [JsonModel], pooled element-wise JSON arrays), formerly Jakar.SystemTextJson; a type can use both generators side by side.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
10.1.0 239 10/16/2026

10.1.0: initial release. ValueStringBuilder and Sizes moved out of Jakar.Extensions 10.10 (type-forwarded, so existing binaries keep working); new ValueUtf8Builder and ValueSpanReader<T>.